[all-commits] [llvm/llvm-project] b49ee0: [LowerExpectIntrinsic] Propagate branch weights th...

ZhiZhuangMTK via All-commits all-commits at lists.llvm.org
Thu Dec 22 14:35:13 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b49ee01fe288abda9269114cc3aef6caade6015a
      https://github.com/llvm/llvm-project/commit/b49ee01fe288abda9269114cc3aef6caade6015a
  Author: Zhi Zhuang <Zhi.Zhuang at mediatek.com>
  Date:   2022-12-22 (Thu, 22 Dec 2022)

  Changed paths:
    M llvm/include/llvm/IR/Intrinsics.td
    M llvm/lib/Transforms/Scalar/LowerExpectIntrinsic.cpp
    A llvm/test/Transforms/LowerExpectIntrinsic/phi_unexpect.ll

  Log Message:
  -----------
  [LowerExpectIntrinsic] Propagate branch weights through phi values when ExpectedValue is unlikely in LowerExpectIntrinsic

Update handlePhiDef to consider the probability argument in an expect.with.probability intrinsic when annotating BranchInsts.
In addition, we also disallow non-constant probability arguments in this intrinsic.

Differential Revsion: https://reviews.llvm.org/D140337




More information about the All-commits mailing list