[PATCH] D86724: [BuildLibCalls] Add argmemonly to more lib calls.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 27 09:44:07 PDT 2020


fhahn created this revision.
fhahn added reviewers: lebedev.ri, hfinkel, efriedma, jdoerfert.
Herald added a subscriber: hiraditya.
Herald added a project: LLVM.
fhahn requested review of this revision.

strspn, strncmp, strcspn, strcasecmp, strncasecmp, memcmp, memchr,
memrchr, memcpy, memmove, memcpy, mempcpy should all only access memory
through their arguments.

I broke out strcoll, because the result depends on the locale, which
might get accessed through memory.

I also added nofree to memcmp, so we do not introduce another attribute
group for in the tests.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D86724

Files:
  llvm/lib/Transforms/Utils/BuildLibCalls.cpp
  llvm/test/Transforms/InferFunctionAttrs/annotate.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86724.288371.patch
Type: text/x-patch
Size: 7244 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200827/d4cb8596/attachment.bin>


More information about the llvm-commits mailing list