[all-commits] [llvm/llvm-project] 0bab2e: [RISCV] Custom lower vector ISD::CTLZ to the minim...
Yeting Kuo via All-commits
all-commits at lists.llvm.org
Thu Jan 12 17:51:52 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 0bab2ecd468918dfcfbc285e0b5675dd20c2cdf2
https://github.com/llvm/llvm-project/commit/0bab2ecd468918dfcfbc285e0b5675dd20c2cdf2
Author: Yeting Kuo <yeting.kuo at sifive.com>
Date: 2023-01-13 (Fri, 13 Jan 2023)
Changed paths:
M llvm/lib/Target/RISCV/RISCVISelLowering.cpp
M llvm/test/CodeGen/RISCV/rvv/ctlz-sdnode.ll
M llvm/test/CodeGen/RISCV/rvv/fixed-vectors-ctlz.ll
Log Message:
-----------
[RISCV] Custom lower vector ISD::CTLZ to the minimum of ISD::CTLZ_ZERO_UNDEF and element size.
D111904 made RISC-V customized lower ISD::CTLZ_ZERO_UNDEF by converting to float
and using the float result. The expected value of CTLZ with zero input is the
element size of input type. Since the result of above method with zero input
must be greater than the element size, for ISD::CTLZ, we could use the minimum
of element size and the result of CTLZ_ZERO_UNDER with same input.
Reviewed By: craig.topper
Differential Revision: https://reviews.llvm.org/D141585
More information about the All-commits
mailing list