[all-commits] [llvm/llvm-project] 4b8f42: [llvm][IR] Treat memcmp and bcmp as libcalls

Paul Kirth via All-commits all-commits at lists.llvm.org
Tue Apr 15 09:32:12 PDT 2025


  Branch: refs/heads/users/ilovepi/bcmp-libcall
  Home:   https://github.com/llvm/llvm-project
  Commit: 4b8f422ee979e6063e553f8a5bc292c5a11e13b4
      https://github.com/llvm/llvm-project/commit/4b8f422ee979e6063e553f8a5bc292c5a11e13b4
  Author: Paul Kirth <paulkirth at google.com>
  Date:   2025-04-15 (Tue, 15 Apr 2025)

  Changed paths:
    M llvm/include/llvm/IR/RuntimeLibcalls.def
    M llvm/test/LTO/Resolution/X86/bcmp-libcall.ll

  Log Message:
  -----------
  [llvm][IR] Treat memcmp and bcmp as libcalls

Since the backend may emit calls to these functions, they should be
treated like other libcalls. If we don't, then it is possible to
have their definitions removed during LTO because they are dead, only to
have a later transform introduce calls to them.

See https://discourse.llvm.org/t/rfc-addressing-deficiencies-in-llvm-s-lto-implementation/84999
for more information.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list