[PATCH] D66461: [CaptureTracker] Comparisons of allocation pointers do not capture
Eli Friedman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 21 11:58:24 PDT 2019
efriedma added a comment.
Yes, you can't capture a pointer that's already captured.
The more interesting scenario is something like this: suppose you have three consecutive 16-byte allocations, laid out one after another. The first and the third are captured; the second is not. Can you capture a pointer to the second allocation using comparisons against the first and third allocations? I think the only reasonable answer here is yes; you've proven the value of every bit of the pointer.
It doesn't really matter if three allocations don't reliably produce this layout; for any particular run of the program, we have to choose some memory layout.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66461/new/
https://reviews.llvm.org/D66461
More information about the llvm-commits
mailing list