[llvm] [DirectX][NFC] Model precise overload type specification of DXIL Ops (PR #83917)

Justin Bogner via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 12 10:48:11 PDT 2024


================
@@ -90,6 +92,15 @@ static ParameterKind getParameterKind(MVT::SimpleValueType VT) {
   case MVT::fAny:
   case MVT::iAny:
     return ParameterKind::OVERLOAD;
+  case MVT::Other:
+    // Handle DXIL-specific overload types
+    {
+      if ((R->getValueAsInt("isHalfOrFloat")) ||
+          (R->getValueAsInt("isI16OrI32"))) {
+        return ParameterKind::OVERLOAD;
+      }
+    }
----------------
bogner wrote:

The extra scope here isn't necessary, and we don't need parens around the `getValueAsInt` calls. Scope comment applies to the other switch as well.

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


More information about the llvm-commits mailing list