[all-commits] [llvm/llvm-project] bf552d: [RISCV][NFC] Tests for (select (const), (const))
Sam Elliott via All-commits
all-commits at lists.llvm.org
Sat May 2 07:07:26 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: bf552d29ee77842cae80b22e182019f7d46b183b
https://github.com/llvm/llvm-project/commit/bf552d29ee77842cae80b22e182019f7d46b183b
Author: Sam Elliott <selliott at lowrisc.org>
Date: 2020-05-02 (Sat, 02 May 2020)
Changed paths:
A llvm/test/CodeGen/RISCV/select-const.ll
Log Message:
-----------
[RISCV][NFC] Tests for (select (const), (const))
Summary:
This just adds some simple cases for testing select of constants. There will be
a follow-up patch that improves code generation in some of these cases.
Reviewed By: luismarques
Differential Revision: https://reviews.llvm.org/D79259
Commit: fe4245a4c1c2051adeeac7007be33bb0558143cf
https://github.com/llvm/llvm-project/commit/fe4245a4c1c2051adeeac7007be33bb0558143cf
Author: Sam Elliott <selliott at lowrisc.org>
Date: 2020-05-02 (Sat, 02 May 2020)
Changed paths:
M llvm/lib/Target/RISCV/RISCVISelLowering.h
M llvm/test/CodeGen/RISCV/select-const.ll
Log Message:
-----------
[RISCV] Implement convertSelectOfConstantsToMath
Summary:
The current lowering of `select` on RISC-V uses a branch instruction to load a
register with one or other value. This is inefficient, especially in the case of
small constants that can be computed easily.
By implementing the TargetLowering::convertSelectOfConstantsToMath hook, some of
the simpler cases are covered that let us avoid introducing a branch in these
cases.
Reviewed By: luismarques
Differential Revision: https://reviews.llvm.org/D79260
Compare: https://github.com/llvm/llvm-project/compare/a4a9a1f671ed...fe4245a4c1c2
More information about the All-commits
mailing list