diff options
author | LiqinWeng <liqin.weng@spacemit.com> | 2025-01-16 10:12:29 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-01-16 10:12:29 +0800 |
commit | d2484127cd27184b373b6be71da87579b8659143 (patch) | |
tree | b2a6cc2594995f130aff97b92de6c67b34304ca2 /llvm/lib/CodeGen/ExpandVectorPredication.cpp | |
parent | c805df69994a1f1e8f095b690c9af9e9c463906b (diff) | |
download | llvm-d2484127cd27184b373b6be71da87579b8659143.zip llvm-d2484127cd27184b373b6be71da87579b8659143.tar.gz llvm-d2484127cd27184b373b6be71da87579b8659143.tar.bz2 |
[VP] IR expansion to Int Func Call (#122867)
Add basic handling for VP ops that can expand to Int intrinsics, which
includes: ctpop/cttz/ctlz/sadd.sat/uadd.sat/ssub.sat/usub.sat/fshl/fshr
Diffstat (limited to 'llvm/lib/CodeGen/ExpandVectorPredication.cpp')
-rw-r--r-- | llvm/lib/CodeGen/ExpandVectorPredication.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/ExpandVectorPredication.cpp b/llvm/lib/CodeGen/ExpandVectorPredication.cpp index 5ca2238..6f4a2c9 100644 --- a/llvm/lib/CodeGen/ExpandVectorPredication.cpp +++ b/llvm/lib/CodeGen/ExpandVectorPredication.cpp @@ -609,6 +609,15 @@ Value *CachingVPExpander::expandPredication(VPIntrinsic &VPI) { case Intrinsic::vp_umin: case Intrinsic::vp_bswap: case Intrinsic::vp_bitreverse: + case Intrinsic::vp_ctpop: + case Intrinsic::vp_ctlz: + case Intrinsic::vp_cttz: + case Intrinsic::vp_sadd_sat: + case Intrinsic::vp_uadd_sat: + case Intrinsic::vp_ssub_sat: + case Intrinsic::vp_usub_sat: + case Intrinsic::vp_fshl: + case Intrinsic::vp_fshr: return expandPredicationToIntCall(Builder, VPI); case Intrinsic::vp_fabs: case Intrinsic::vp_sqrt: |