[PATCH] D64451: [PoisonChecking] Validate inbounds annotation on getelementptr where possible
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 14 16:57:05 PDT 2019
jdoerfert added inline comments.
================
Comment at: lib/Transforms/Instrumentation/PoisonChecking.cpp:280
+ break;
+ }
};
----------------
aqjune wrote:
> A silly question: where is the poison-ness of operands of GEP checked at?
I think this is relates to your other question: nowhere yet (I think)
Though, this is a really good point. The check for an inbound gep could include one to ensure a valid base pointer. How to do that is tricky though. If the base allocation is known, one can substract the base pointer from the base allocation and do `diff >= 0 && diff <= length`. If the base allocation is not known, we would need to track more information throughout the program. There are different ways to do this but I guess the first case should be covered next.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D64451/new/
https://reviews.llvm.org/D64451
More information about the llvm-commits
mailing list