[llvm] d95513a - [RISCV] remove useless code
via llvm-commits
llvm-commits at lists.llvm.org
Mon May 16 05:55:13 PDT 2022
Author: Liqin.Weng
Date: 2022-05-16T12:54:03Z
New Revision: d95513ae3a73388cbe18fa1bd2c76fec70f3ec06
URL: https://github.com/llvm/llvm-project/commit/d95513ae3a73388cbe18fa1bd2c76fec70f3ec06
DIFF: https://github.com/llvm/llvm-project/commit/d95513ae3a73388cbe18fa1bd2c76fec70f3ec06.diff
LOG: [RISCV] remove useless code
When legality check for vectoring reduction, hasVInstructions() check be unneeded. RISCV can only loop vectorization with hasVInstructions()
Reviewed By: kito-cheng, craig.topper
Differential Revision: https://reviews.llvm.org/D125460
Added:
Modified:
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
Removed:
################################################################################
diff --git a/llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h b/llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
index a0a5110963521..cdec074dc2a46 100644
--- a/llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
+++ b/llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
@@ -171,9 +171,6 @@ class RISCVTTIImpl : public BasicTTIImplBase<RISCVTTIImpl> {
bool isLegalToVectorizeReduction(const RecurrenceDescriptor &RdxDesc,
ElementCount VF) const {
- if (!ST->hasVInstructions())
- return false;
-
if (!VF.isScalable())
return true;
More information about the llvm-commits
mailing list