Dwarf (64) fixes / Issue 5569#18
Conversation
MartinNowak
commented
Mar 19, 2011
- Made CFA state machine 64 aware
- debug ranges needed to be address size
- corrected frame_base calculation (also 32)
- correct line number information for multiobj (also 32)
...and required to be multiple of address size.
- different data_alignment_factor for 64 - different dwarf register mapping for x64-64
- This should allow to for farfunc or other functions that have a bigger outer/inner frame base gap.
- This makes variable expressions relative to the stack pointer of the caller, the address tracked by DW_AT_frame_base.
- Besides the module file stored in dwarf_initmodule this includes files referenced by linnum_data and files from function code gen.
- in case of multiobj line data was always appended leading to garbage .debug_line programs
|
Nice! You just gave me my weekend back, or at least time to work on other stuff. I was really looking to find and fix the bug you fixed in f16c68b. I'm far from an expert in this code, but nothing stood out to me as likely wrong from my reading of it. |
|
only D2 fixes :( |
|
Marenz: D1 will get the same set of changes. The backends between the two compilers are essentially identical. dawgfoto: Playing with these changes I've noticed a bug (and haven't gone back to before your changes to make sure they're not an old bug), but it looks like the args are getting reversed somewhere. For example: (gdb) step Notice the frame info is showing f then val, but the code has val then f. The actual values are semi correct. Notice that val is both second and has 0 even though -999L is what was passed. Single stepping once more into the function and the value of val is correct: (gdb) print val |
|
braddr: |