[llvm] [RISCV][ISel] Combine vector fadd/fsub/fmul with fp extend. (PR #81248)

Wang Pengcheng via llvm-commits llvm-commits at lists.llvm.org
Sat Feb 17 22:18:32 PST 2024


================
@@ -13273,22 +13281,34 @@ struct NodeExtensionHelper {
     return OrigOperand.getOpcode() == RISCVISD::VMV_V_X_VL;
   }
 
+  /// Get the extended opcode.
+  unsigned getExtOpc(ExtKind SupportsExt) const {
+    switch (SupportsExt) {
----------------
wangpc-pp wrote:

Can we just remove `ExtKind` (that means we use `std::optional<int>`) and use `RISCVISD::VSEXT_VL`, `RISCVISD::VZEXT_VL` and `RISCVISD::FP_EXTEND_VL` directly?

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


More information about the llvm-commits mailing list