[llvm] [RISCV][GISel] Add instruction selection for G_FADD/G_FSUB/G_FMUL/G_FDIV with F/D extensions. (PR #69808)

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 25 10:35:28 PDT 2023


================
@@ -201,13 +202,11 @@ RISCVLegalizerInfo::RISCVLegalizerInfo(const RISCVSubtarget &ST) {
 
   // FP Operations
 
-  if (ST.hasStdExtF()) {
-    auto &FPOpActions =
-        getActionDefinitionsBuilder({G_FADD, G_FSUB, G_FMUL, G_FDIV})
-            .legalFor({s32});
-    if (ST.hasStdExtD())
-      FPOpActions.legalFor({s64});
-  }
+  getActionDefinitionsBuilder({G_FADD, G_FSUB, G_FMUL, G_FDIV})
----------------
topperc wrote:

It was intended to be stylistic. It was suggested in earlier review. It should be in the legalizer patch.

https://github.com/llvm/llvm-project/pull/69808


More information about the llvm-commits mailing list