]> granicus.if.org Git - llvm/commitdiff
GlobalISel: Fix missing version of customFor
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Fri, 17 May 2019 11:49:41 +0000 (11:49 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Fri, 17 May 2019 11:49:41 +0000 (11:49 +0000)
Add the list of pairs analagous, like legalFor and customFor has.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@361020 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/CodeGen/GlobalISel/LegalizerInfo.h

index d38dbf9e0d1f47deb8c8cdb4db93f032c95bf87f..7b7c899e009941747d6cf7994501686be577ee76 100644 (file)
@@ -650,6 +650,13 @@ public:
   LegalizeRuleSet &customFor(std::initializer_list<LLT> Types) {
     return actionFor(LegalizeAction::Custom, Types);
   }
+
+  /// The instruction is custom when type indexes 0 and 1 is any type pair in the
+  /// given list.
+  LegalizeRuleSet &customFor(std::initializer_list<std::pair<LLT, LLT>> Types) {
+    return actionFor(LegalizeAction::Custom, Types);
+  }
+
   LegalizeRuleSet &customForCartesianProduct(std::initializer_list<LLT> Types) {
     return actionForCartesianProduct(LegalizeAction::Custom, Types);
   }