[RISCV] Move fli selection in RISCVISelDAGToDAG.cpp. NFC
authorCraig Topper <craig.topper@sifive.com>
Wed, 22 Mar 2023 02:15:30 +0000 (19:15 -0700)
committerCraig Topper <craig.topper@sifive.com>
Wed, 22 Mar 2023 02:33:27 +0000 (19:33 -0700)
commitb50c6857a45b8fa753bde44efcea7d0000c55ac5
tree6e734b1d2b695d97d249ad31730f9cef89347636
parent4dc04557d71c1752c53eb8025957df8f1bdbb1e1
[RISCV] Move fli selection in RISCVISelDAGToDAG.cpp. NFC

We custom isel for ConstantFP that has higher priority than isel
patterns. We were previously detecting valid FP constants for fli
to early exit from the custom code. This detection called
getLoadFPImm. Then we would run the isel patterns which would call
getLoadFPImm a second time.

With a little bit more code we can directly select the fli instruction
in the custom handler and avoid a second call.

Remove the incorrect mayRaiseFPException flag from the FLI instructions.

Reviewed By: joshua-arch1

Differential Revision: https://reviews.llvm.org/D146093
llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
llvm/lib/Target/RISCV/RISCVISelLowering.cpp
llvm/lib/Target/RISCV/RISCVISelLowering.h
llvm/lib/Target/RISCV/RISCVInstrInfoZfa.td