-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Native AOT DWARF info contains many overlapping ranges #83233
Comments
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch, @kunalspathak Issue Details
This seems like it's related to inlining. If so, I would expect
|
I'm struggling to read the output here -- what is the error saying? What are the source mappings returned from the JIT that resulted in these DWARF ranges (or is this from variable ranges?) The JIT does not support reporting debug information in inlinees unless rich debug information is enabled ( |
Maybe ILC is emitting an incorrect |
Sorry, that was a bad exmaple, maybe this one is better:
|
The nesting is a different issue. |
If you use the |
Gotcha, thank you, I'll try to take a closer look. It sounds feasible that the JIT is emitting an incorrect variable range here. |
Looking at the following error: error: DIEs have overlapping address ranges:
0x0006a2a3: DW_TAG_lexical_block [35] * (0x0006a260)
DW_AT_low_pc [DW_FORM_addr] (0x0000000000072e05)
DW_AT_high_pc [DW_FORM_data8] (0x0000000000000007)
0x0006a284: DW_TAG_lexical_block [35] * (0x0006a260)
DW_AT_low_pc [DW_FORM_addr] (0x0000000000072dcc)
DW_AT_high_pc [DW_FORM_data8] (0x000000000000003c) Those lexical scopes are clearly not nested correctly in the DWARF info. The function is VarLocInfo count is 4
; Variable debug info: 3 live ranges, 3 vars for method Interop+Sys:StrError(int):System.String
(V00 arg0) : From 00000000h to 0000002Ch, in rdi
(V01 loc0) : From 0000002Ch to 00000068h, in rbx
(V02 loc1) : From 00000065h to 0000006Ch, in rdi which seems quite reasonable. So probably the error is in the translation of these ranges into DWARF format. There is no expectation that live var ranges are guaranteed to be lexically nested, so if DwarfGen is creating lexical scopes for each live var ranges then it makes sense that it causes errors. |
So I guess those inner scopes are created here: I would expect we shouldn't be creating these scopes at all and relying on the code that adds the variables to |
Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas Issue Details
This seems like it's related to inlining. If so, I would expect
|
I fixed most of the overlapping range issues in #89488. It fell into a JitInterface trap where on JitInterface we have fields named "Length" that are not actually populated as lengths in RyuJIT (#5282). I believe the only remaining issue is with overlapping regions that are related to |
Yeah, the vast majority of the issues discussed here have been fixed. I filed a new bug for the last few issues that are left. #90209 |
dwarfdump --verify
shows examples of this:This seems like it's related to inlining. If so, I would expect
DW_TAG_inlined_subroutine
entries, but I'm not seeing anything from the JITed code, only from the linked C++.The text was updated successfully, but these errors were encountered: