Sometimes when using tools for reading line number information out of objects generated by agbcc, you'd get the follwing error:
DWARF error: mangled line number section
This is presumably caused by the function size_of_line_info (in gcc/dwarf2out.c) sometimes mispredicting the actual size of the rest of the .debug_line section. This was fixed here by generating label deltas instead of using that function (as is done in more recent versions of GCC).
The optional -ffix-debug-line flag enables this new behavior.
Note: that fix probably needs to eventually be ported to agbcc_arm as well as any fork featuring agbcp.
I'm only now seeing that there's another debug info related PR in (#49) featuring the addition of a new flag. Perhaps it would be interesting to merge the flags into an unified one that either updates/fixes debug info generation or restores the old buggy one.
Sometimes when using tools for reading line number information out of objects generated by agbcc, you'd get the follwing error:
This is presumably caused by the function
size_of_line_info
(in gcc/dwarf2out.c) sometimes mispredicting the actual size of the rest of the.debug_line
section. This was fixed here by generating label deltas instead of using that function (as is done in more recent versions of GCC).The optional
-ffix-debug-line
flag enables this new behavior.Note: that fix probably needs to eventually be ported to agbcc_arm as well as any fork featuring agbcp.
I'm only now seeing that there's another debug info related PR in (#49) featuring the addition of a new flag. Perhaps it would be interesting to merge the flags into an unified one that either updates/fixes debug info generation or restores the old buggy one.