Skip to content

Conversation

@DanBlackwell
Copy link
Contributor

@DanBlackwell DanBlackwell commented Nov 18, 2025

LLDB memsets new allocas to zero. It does this in order to be able to display a friendly 'variable is uninitialized' message rather than garbage. Unfortunately this use of a variable before its lifetime.start disagrees with the memtag-stack tagging pass.

This patch attaches a piece of metadata to these memsets, so that the memtag-stack tagging pass can recognize them and work around them appropriately.

Paired with: swiftlang/llvm-project#11846.

rdar://162206592

LLDB memsets new allocas to zero. It does this in order to be able to display a friendly 'variable is uninitialized' message rather than garbage. Unfortunately this use of a variable before its lifetime.start disagrees with the memtag-stack tagging pass.

This patch attaches a piece of metadata to these memsets, so that the memtag-stack tagging pass can recognize them and work around them appropriately.

rdar://162206592
@DanBlackwell
Copy link
Contributor Author

@swift-ci please 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