[PATCH] D66079: [SimplifyLibCalls] Add dereferecanble bytes from known callsites úWI]
Dávid Bolvanský via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 12 04:29:24 PDT 2019
xbolva00 created this revision.
xbolva00 added reviewers: jdoerfert, efriedma.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
int mm(char *a, char *b) {
return memcmp(a,b,16);
}
Currently:
define dso_local i32 @mm(i8* nocapture readonly %a, i8* nocapture readonly %b) local_unnamed_addr #1 {
entry:
%call = tail call i32 @memcmp(i8* %a, i8* %b, i64 16)
ret i32 %call
}
After patch:
define dso_local i32 @mm(i8* nocapture readonly dereferenceable(16) %a, i8* nocapture readonly dereferenceable(16) %b) local_unnamed_addr #1 {
entry:
%call = tail call i32 @memcmp(i8* nonnull %a, i8* nonnull %b, i64 16)
ret i32 %call
}
Repository:
rL LLVM
https://reviews.llvm.org/D66079
Files:
include/llvm/Transforms/Utils/SimplifyLibCalls.h
lib/Transforms/Utils/SimplifyLibCalls.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D66079.214599.patch
Type: text/x-patch
Size: 5686 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190812/9d1a5c14/attachment.bin>
More information about the llvm-commits
mailing list