This patch reduces the number of unpredictable branches.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/Target/RISCV/RISCVISelLowering.cpp | ||
---|---|---|
10919 | Are there any tests for the SETEQ case? |
llvm/lib/Target/RISCV/RISCVISelLowering.cpp | ||
---|---|---|
10919 | I do not find LLVM IR that would cover the SETEQ case, perhaps a mir could be constructed? %c = call i64 @llvm.umax.i64(i64 %a, i64 1) %c = call i64 @llvm.umax.i64(i64 1, i64 %a) After Initial selection DAG, both are the same DAG. So both will be SETNE |
LGTM
llvm/lib/Target/RISCV/RISCVISelLowering.cpp | ||
---|---|---|
10919 | Ok. I think maybe it gets adjusted in LowerSelect to put the constant in the false operand. |
This comment mixes SelectionDAG names and instruction names. Can we use SelectionDAG throughout?