[llvm] [NFC][LLVM] Refactor rounding mode detection of constrained fp intrinsic IDs (PR #90854)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu May 2 08:36:35 PDT 2024


================
@@ -1491,7 +1491,19 @@ bool Intrinsic::isConstrainedFPIntrinsic(ID QID) {
 #define INSTRUCTION(NAME, NARG, ROUND_MODE, INTRINSIC)                         \
   case Intrinsic::INTRINSIC:
 #include "llvm/IR/ConstrainedOps.def"
+#undef INSTRUCTION
     return true;
+  default:
+    return false;
+  }
+}
+
+bool Intrinsic::hasConstrainedFPRoundingModeOperand(Intrinsic::ID QID) {
----------------
arsenm wrote:

We should probably use SearchableTabless and generate this function 

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


More information about the llvm-commits mailing list