Skip to content

Conversation

@felipepiovezan
Copy link

@felipepiovezan felipepiovezan commented Aug 13, 2025

The first commit just factors out a helper function to be reused by the second commit.
We should find a place for that function in an upstream file later.

Plans stepping through a swift_task_switch are often the last sub-plan
for a StepOver action, meaning the plan's destination is also the PC
where users will take control of the program. As such, it is crucial
that these plans skip over the prologue of their destination function,
otherwise most variables won't be in scope.

rdar://149391650

…untime

This will be useful for an upcoming commit. This is also a good
candidate to be placed in a non-swift specific file, if there are uses
for it upstream. This should be revisited.
@felipepiovezan felipepiovezan requested a review from a team as a code owner August 13, 2025 16:33
@felipepiovezan
Copy link
Author

@swift-ci test

@felipepiovezan
Copy link
Author

I think this is once again being tripped by debug info

Plans stepping through a swift_task_switch are often the last sub-plan
for a StepOver action, meaning the plan's destination is also the PC
where users will take control of the program. As such, it is crucial
that these plans skip over the prologue of their destination function,
otherwise most variables won't be in scope.

Because x86 and arm diverge on the codegen for `}` in a scope, I had to
add a `print` statement in the for loop of the affected test.
@felipepiovezan felipepiovezan force-pushed the felipe/step_over_variables branch from d2d889a to 3ed5f1d Compare August 13, 2025 21:19
@felipepiovezan
Copy link
Author

Turned out to be a x86 vs arm difference on the debug info for } in blocks.

@felipepiovezan
Copy link
Author

@swift-ci test

@felipepiovezan
Copy link
Author

@swift-ci test windows platform

1 similar comment
@JDevlieghere
Copy link

@swift-ci test windows platform

@adrian-prantl adrian-prantl merged commit d7216d8 into swiftlang:swift/release/6.2 Aug 15, 2025
3 checks passed
@felipepiovezan felipepiovezan deleted the felipe/step_over_variables branch August 15, 2025 17:45
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.

3 participants