diff options
author | Sam Elliott <selliott@lowrisc.org> | 2020-05-02 15:05:12 +0100 |
---|---|---|
committer | Sam Elliott <selliott@lowrisc.org> | 2020-05-02 15:05:57 +0100 |
commit | fe4245a4c1c2051adeeac7007be33bb0558143cf (patch) | |
tree | 126f709c06c212a12bf57ecd95fec76dfcbd6367 /clang/unittests/Format/FormatTestJava.cpp | |
parent | bf552d29ee77842cae80b22e182019f7d46b183b (diff) | |
download | llvm-fe4245a4c1c2051adeeac7007be33bb0558143cf.zip llvm-fe4245a4c1c2051adeeac7007be33bb0558143cf.tar.gz llvm-fe4245a4c1c2051adeeac7007be33bb0558143cf.tar.bz2 |
[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
Diffstat (limited to 'clang/unittests/Format/FormatTestJava.cpp')
0 files changed, 0 insertions, 0 deletions