[all-commits] [llvm/llvm-project] 20e989: [BuildLibCalls] Add argmemonly to more lib calls.

Florian Hahn via All-commits all-commits at lists.llvm.org
Fri Aug 28 01:52:19 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 20e989e9de6abcf9a684978a2688acc4ea01036f
      https://github.com/llvm/llvm-project/commit/20e989e9de6abcf9a684978a2688acc4ea01036f
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2020-08-28 (Fri, 28 Aug 2020)

  Changed paths:
    M llvm/lib/Transforms/Utils/BuildLibCalls.cpp
    M llvm/test/Transforms/InferFunctionAttrs/annotate.ll

  Log Message:
  -----------
  [BuildLibCalls] Add argmemonly to more lib calls.

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

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

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D86724




More information about the All-commits mailing list