Re: [lldb-dev] DW_OP_deref handling

2018-10-12 Thread Greg Clayton via lldb-dev
> On Oct 12, 2018, at 9:53 AM, Adrian Prantl wrote: > > > >> On Oct 11, 2018, at 11:16 AM, Greg Clayton via lldb-dev >> wrote: >> >> DWARF5 finally added the ability to track what each value means on the >> expression stack. Prior to DWARF 5, we had no idea what each entry on the >> expr

Re: [lldb-dev] DW_OP_deref handling

2018-10-12 Thread Davide Italiano via lldb-dev
Follow up. This turned out to be a bug in the swift specific support, so I don't think the DWARF parser code is wrong here. Thanks! -- Davide On Thu, Oct 11, 2018 at 10:52 AM Davide Italiano wrote: > > Hi Greg, > I have this issue that I suspect is a bug in lldb’s handling of DW_OP_deref. > I wa

Re: [lldb-dev] DW_OP_deref handling

2018-10-12 Thread Adrian Prantl via lldb-dev
> On Oct 12, 2018, at 9:53 AM, Adrian Prantl via lldb-dev > wrote: > > > >> On Oct 11, 2018, at 11:16 AM, Greg Clayton via lldb-dev >> wrote: >> >> DWARF5 finally added the ability to track what each value means on the >> expression stack. Prior to DWARF 5, we had no idea what each entry

Re: [lldb-dev] DW_OP_deref handling

2018-10-12 Thread Adrian Prantl via lldb-dev
> On Oct 11, 2018, at 11:16 AM, Greg Clayton via lldb-dev > wrote: > > DWARF5 finally added the ability to track what each value means on the > expression stack. Prior to DWARF 5, we had no idea what each entry on the > expression value stack was (file address, load address > (Value::eValue

Re: [lldb-dev] DW_OP_deref handling

2018-10-12 Thread Greg Clayton via lldb-dev
> On Oct 11, 2018, at 3:55 PM, Davide Italiano wrote: > > On Thu, Oct 11, 2018 at 1:38 PM Greg Clayton wrote: >> >> I am happy to look at any DWARF expressions you have and help figure out >> where the change needs to go or how the expression need to be fixed. >> > > Thank you for your hel

Re: [lldb-dev] DW_OP_deref handling

2018-10-11 Thread Davide Italiano via lldb-dev
On Thu, Oct 11, 2018 at 1:38 PM Greg Clayton wrote: > > I am happy to look at any DWARF expressions you have and help figure out > where the change needs to go or how the expression need to be fixed. > Thank you for your help, it's greatly appreciated. hopefully we'll have a more precise debugge

Re: [lldb-dev] DW_OP_deref handling

2018-10-11 Thread Greg Clayton via lldb-dev
I am happy to look at any DWARF expressions you have and help figure out where the change needs to go or how the expression need to be fixed. Greg > On Oct 11, 2018, at 12:32 PM, Davide Italiano wrote: > > On Thu, Oct 11, 2018 at 11:16 AM Greg Clayton > wrote: >>

Re: [lldb-dev] DW_OP_deref handling

2018-10-11 Thread Davide Italiano via lldb-dev
On Thu, Oct 11, 2018 at 11:16 AM Greg Clayton wrote: > > The issue is DW_OP_deref dereferences a pointer and pushes it onto the stack. > The code currently, for a load address that is on top of the stack does: > > Value::ValueType value_type = stack.back().GetValueType(); > switch (value_type) {

Re: [lldb-dev] DW_OP_deref handling

2018-10-11 Thread Greg Clayton via lldb-dev
The issue is DW_OP_deref dereferences a pointer and pushes it onto the stack. The code currently, for a load address that is on top of the stack does: Value::ValueType value_type = stack.back().GetValueType(); switch (value_type) { case Value::eValueTypeLoadAddress: if (exe_ctx) { if (proce