[PATCH] D95122: [Libcalls, Attrs] Annotate libcalls with noundef
Juneyoung Lee via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 21 08:18:20 PST 2021
aqjune added a comment.
In D95122#2512578 <https://reviews.llvm.org/D95122#2512578>, @xbolva00 wrote:
> but we are talking about specific libcalls, so eg. strlen(p), where p is null, is UB.
The problem is that in theory p can be partially undef which is still dereferenceable. Imagine a pointer that points into somewhere within bounds of alloca [16 x i8] but the lowest 4 bits of the offset is undefined.
If strlen's first argument has noundef, this will also be UB, which is more undefined than before.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95122/new/
https://reviews.llvm.org/D95122
More information about the llvm-commits
mailing list