Details
- Reviewers
craig.topper benshi001
Diff Detail
Unit Tests
Event Timeline
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
194 | Why do we need a table to return a 1 for every legal scalable vector type? There's gotta be better ways to do that. I don't believe that 1 is the correct answer for RISC-V though. It's a vid.v, a vrsub.vx, and a vrgather.vv if I remember correctly. That's at least a cost of 3 assuming an optimal implementation of vrgather.vv. | |
230 | This doesn't seem to go with the title of this patch. | |
246 | There are no problems with <vscale x 1 x eltty> in the code generator that I'm aware of. Please explain. | |
llvm/test/Transforms/LoopVectorize/RISCV/riscv-vector-reverse.ll | ||
4 | Shouldn't a reverse test have reverse intrinsics in it? Or did instcombine remove them? | |
5 | Do any of the check lines in this file come from -debug-only=loop-vectorize? | |
8 | Remove unneeded attributes please |
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
230 | To ensure that the Load/store's InstructionCost‘s state is set to Valid, when VF.isScalar() == true |
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
230 | Can you put it in a different patch that is applied before this one? |
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
194 |
CostTableLookup | |
230 | I add the test case, Pls review: https://reviews.llvm.org/D125866 |
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
194 | Since you're returning the same cost for every legal vector type, I think this is equivalent to: if (LT.second.isScalableVector()) return LT.first * 1 But I still don't believe 1 is the correct value. |
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp | ||
---|---|---|
246 | Fixed | |
llvm/test/Transforms/LoopVectorize/RISCV/riscv-vector-reverse.ll | ||
4 | pls review: https://reviews.llvm.org/D125866 |
Why do we need a table to return a 1 for every legal scalable vector type? There's gotta be better ways to do that.
I don't believe that 1 is the correct answer for RISC-V though. It's a vid.v, a vrsub.vx, and a vrgather.vv if I remember correctly. That's at least a cost of 3 assuming an optimal implementation of vrgather.vv.