[PATCH] D145645: [RISCV] Print Zfa fli instruction FP values in a more adaptive way.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 10 07:37:46 PST 2023


craig.topper added inline comments.


================
Comment at: llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp:167
     O << "nan";
-  else
-    O << RISCVLoadFPImm::getFPImm(MO.getImm());
+  } else {
+    float FPVal = RISCVLoadFPImm::getFPImm(Imm);
----------------
reames wrote:
> To check my understanding - it's okay to treat FLI.D (doubles) as floats here since the only values for doubles which aren't representable exactly as floats are the ones we explicitly emit symbolically just above?  And the same basic argument for floats?
That's correct.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D145645/new/

https://reviews.llvm.org/D145645



More information about the llvm-commits mailing list