Skip to content

[SIL] Key consume addr checking off var_decl attr. #72211

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

Merged
merged 20 commits into from
Mar 9, 2024

Conversation

nate-chandler
Copy link
Contributor

Previously, the lexical attribute on alloc_stack instructions was used. This doesn't work for values without lexical lifetimes which are consumed, e.g. stdlib CoW types. Here, the new var_decl attribute on alloc_stack is keyed off of instead. This flag encodes exactly that a value corresponds to a source-level VarDecl, which is the condition under which checking needs to run.

Renamed "getUsesMoveableValueDebugInfo" to "usesMoveableValueDebugInfo".
Clarifies the predicate from "does the receiver have the
usesMoveableValueDebugInfo field set?" to "does the receiver use moveable
value debug info?".
Help avoid errors with boolean flags by introducing
UsesMoveableValueDebugInfo_t.
Help avoid errors with boolean flags by using the new
UsesMoveableValueDebugInfo_t.
Help avoid errors with boolean flags by using the new
UsesMoveableValueDebugInfo_t.
@nate-chandler nate-chandler force-pushed the var_decl-alloc_stack branch from f740c0b to aa803c6 Compare March 9, 2024 05:26
@nate-chandler nate-chandler force-pushed the var_decl-alloc_stack branch from aa803c6 to b3473eb Compare March 9, 2024 06:28
Previously, the lexical attribute on allock_stack instructions was used.
This doesn't work for values without lexical lifetimes which are
consumed, e.g. stdlib CoW types.  Here, the new var_decl attribute on
alloc_stack is keyed off of instead.  This flag encodes exactly that a
value corresponds to a source-level VarDecl, which is the condition
under which checking needs to run.
@nate-chandler nate-chandler force-pushed the var_decl-alloc_stack branch from b3473eb to a54a8dd Compare March 9, 2024 13:29
@nate-chandler
Copy link
Contributor Author

@swift-ci please test

@nate-chandler
Copy link
Contributor Author

@swift-ci please test macos platform

@nate-chandler nate-chandler marked this pull request as ready for review March 9, 2024 21:58
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