-
Notifications
You must be signed in to change notification settings - Fork 13.5k
Stack overflow / segfault in getASTRecordLayout
inspecting variables for rust enum values with matching field names
#114068
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
Comments
@llvm/issue-subscribers-clang-frontend Author: Lloyd Wallis (LloydW93)
Potentially similar issues:
https://github.com//issues/64628
https://github.com//issues/43604
https://github.com//issues/63667
https://github.com//issues/66335
https://github.com//issues/53490
Probably related issue/fix: When debugging the following rust code using rust-lldb (a script that loads some extra formatters):
The top/tail of the stack:
The loop starts when the synthetic lookup function calls GetByteSize() on
This is obviously circular and incorrect - and though I'm not sure if that's the symbol file or the interpretation, I'm hoping there's something that can be done to handle that better... If we rename the Enum value's field to
I've reproduced this with lldb-18, lldb-19.1, and nightly. Built using rust 1.82. |
Ah this reminds me of the issue I saw with static union members, where we thought the static data member was actually not a static, and went down the same recursion trying to lay out the member. (#68300) Could you attach the DWARF that gets produced for this (e.g., using |
@llvm/issue-subscribers-lldb Author: Lloyd Wallis (LloydW93)
Potentially similar issues:
https://github.com//issues/64628
https://github.com//issues/43604
https://github.com//issues/63667
https://github.com//issues/66335
https://github.com//issues/53490
Probably related issue/fix: When debugging the following rust code using rust-lldb (a script that loads some extra formatters):
The top/tail of the stack:
The loop starts when the synthetic lookup function calls GetByteSize() on
This is obviously circular and incorrect - and though I'm not sure if that's the symbol file or the interpretation, I'm hoping there's something that can be done to handle that better... If we rename the Enum value's field to
I've reproduced this with lldb-18, lldb-19.1, and nightly. Built using rust 1.82. |
dwardump.txt |
Potentially similar issues:
#64628
#43604
#63667
#66335
#53490
Probably related issue/fix:
#68300
#68135
When debugging the following rust code using rust-lldb (a script that loads some extra formatters):
frame variable
aftermap
has been declared results in a stack overflow, followed by a segfault. The diagnostic.log is empty.The top/tail of the stack:
The loop starts when the synthetic lookup function calls GetByteSize() on
map.base.table
's type (<String, OuterEnum>
). When inspecting the debug symbols, we can see there appears to be recursion:This is obviously circular and incorrect - and though I'm not sure if that's the symbol file or the interpretation, I'm hoping there's something that can be done to handle that better...
If we rename the Enum value's field to
ValueType1
, then everything works:I've reproduced this with lldb-18, lldb-19.1, and nightly. Built using rust 1.82.
The text was updated successfully, but these errors were encountered: