[all-commits] [llvm/llvm-project] 11c8ef: [Inline] Introduce Constant::hasOneLiveUse, use it...

erikdesjardins via All-commits all-commits at lists.llvm.org
Thu Oct 7 08:33:42 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 11c8efd4db0fe58a2858459353cc5c0c41565ee5
      https://github.com/llvm/llvm-project/commit/11c8efd4db0fe58a2858459353cc5c0c41565ee5
  Author: Erik Desjardins <erikdesjardinspublic at gmail.com>
  Date:   2021-10-07 (Thu, 07 Oct 2021)

  Changed paths:
    M llvm/include/llvm/IR/Constant.h
    M llvm/lib/Analysis/InlineCost.cpp
    M llvm/lib/IR/Constants.cpp
    A llvm/test/Transforms/Inline/inline-cost-dead-users.ll
    M llvm/test/Transforms/Inline/last-callsite.ll

  Log Message:
  -----------
  [Inline] Introduce Constant::hasOneLiveUse, use it instead of hasOneUse in inline cost model (PR51667)

Otherwise, inlining costs may be pessimized by dead constants.

Fixes https://bugs.llvm.org/show_bug.cgi?id=51667.

Reviewed By: mtrofin, aeubanks

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




More information about the All-commits mailing list