Skip to content

Conversation

@nikic
Copy link
Contributor

@nikic nikic commented Sep 30, 2024

After #110280 we use EarliestEscapeInfo, so callCapturesBefore() is mostly redundant. It can provide better results in some cases because EEI does an approximation across all captures. I hope that it's good enough in practice, as this is the last remaining user of callCapturesBefore(), so we'll be able to remove this API entirely.

After llvm#110280 we use EarliestEscapeInfo, so callCapturesBefore()
is mostly redundant. It can provide better results in some cases
because EEI does an approximation across all captures. I hope
that it's good enough in practice, as this is the last remaining
user of callCapturesBefore(), so we'll be able to remove this
API entirely.
@nikic
Copy link
Contributor Author

nikic commented Sep 30, 2024

Okay, it looks like the more precise analysis here does provide enough additional value to keep it...

@nikic nikic closed this Sep 30, 2024
antoniofrighetto added a commit to antoniofrighetto/llvm-project that referenced this pull request Jan 7, 2026
…alysis (NFCI)

Following up on llvm#110484, it should be possible to drop
`callCaptureBefore`, whose last user is MemCpyOpt, while
retaining its additional precision by encapsulating it
into a dedicated CapturesBeforeAnalysis. This uses
`PointerMayBeCapturedBefore` and is more precise than
EarliestEscapeAnalysis, though more expensive. Also allow
users to query them in chain when needed.
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