[Dwarf-Discuss] DWARF piece questions

Michael Eager eager at eagercon.com
Fri Jan 27 23:23:07 PST 2017

On 01/27/2017 05:32 PM, Cary Coutant wrote:
> How about if we define this in terms of a left shift instead of a bit
> offset relative to the least-significant bit?
> "If the location is a register, the value is shifted left by offset
> bits within the register."

Extracting bits is conceptually clearer than a shift and less confusing.

I presume you mean that the value is right-shifted, not left-shifted.
Right-shifting aligns the desired bits at the LSB end.  I think.
And you need to specify that it is masked.  And you probably want to
specify sign extension, or zero fill, but I'm not sure which.  What happens
if the register is a FP reg?  What does it mean to right-shift a floating
point register?

Seems to be way more complicated to me.

Michael Eager	 eager at eagercon.com
1960 Park Blvd., Palo Alto, CA 94306  650-325-8077

More information about the Dwarf-Discuss mailing list