Skip to content

[lldb][swift] Create thread plan for stepping through Allocating Init #10576

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

Open
wants to merge 1 commit into
base: swift/release/6.2
Choose a base branch
from

Conversation

felipepiovezan
Copy link

These trampolines have a well defined target, which can be extracted from the demangle tree. A similar strategy is already adopted for stepping into conformance code. This allows LLDB to create a StepThrough plan with a target symbol, instead of a plan that keep taking steps until it reaches some interesting location.

We already had a test for this, but we rely on the "step avoid libraries" setting to emulate the case of "avoid libraries without debug info". However, they are not exactly equivalent, so the test mislead us into believing stepping was working. A future patch should try to fold the setting-checking code into
ThreadPlanShouldStopHere::DefaultShouldStopCallback.

These trampolines have a well defined target, which can be extracted
from the demangle tree. A similar strategy is already adopted for
stepping into conformance code. This allows LLDB to create a StepThrough
plan with a target symbol, instead of a plan that keep taking steps
until it reaches some interesting location.

We already had a test for this, but we rely on the "step avoid
libraries" setting to emulate the case of "avoid libraries without debug
info". However, they are not exactly equivalent, so the test mislead us
into believing stepping was working. A future patch should try to fold
the setting-checking code into
ThreadPlanShouldStopHere::DefaultShouldStopCallback.

With this patch, the test now works regardless of whether debug info is
present or not.
@felipepiovezan felipepiovezan requested a review from a team as a code owner April 29, 2025 02:04
@felipepiovezan felipepiovezan force-pushed the felipe/fix-stepping-into-allocating-init branch from 33be91d to 345eddf Compare April 29, 2025 02:04
@felipepiovezan
Copy link
Author

@swift-ci test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant