[PATCH] D155412: [ConstraintElim] Add facts implied by MinMaxIntrinsic

Yingwei Zheng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 16 16:43:36 PDT 2023


dtcxzyw created this revision.
dtcxzyw added reviewers: nikic, fhahn.
Herald added subscribers: StephenFan, JDevlieghere, hiraditya.
Herald added a project: All.
dtcxzyw requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Fixes https://github.com/llvm/llvm-project/issues/63896 and https://github.com/rust-lang/rust/issues/113757.
This patch adds facts implied by llvm.smin/smax/umin/umax intrinsics.
To materialize the assumptions implied by these minmax intrinsics, it creates temporary CmpInsts and deletes them in the end.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D155412

Files:
  llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
  llvm/test/Transforms/ConstraintElimination/minmax.ll
  llvm/test/Transforms/ConstraintElimination/reproducer-remarks.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D155412.540834.patch
Type: text/x-patch
Size: 5475 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230716/f89b93f7/attachment.bin>


More information about the llvm-commits mailing list