[VP] Make VectorBuilder take IRBuilderBase instead of IRBuilder<>
authorCraig Topper <craig.topper@sifive.com>
Mon, 21 Mar 2022 16:09:13 +0000 (09:09 -0700)
committerCraig Topper <craig.topper@sifive.com>
Mon, 21 Mar 2022 16:17:37 +0000 (09:17 -0700)
IRBuilder<> assumes specific values for template parameters.
IRBuilderBase abstracts away the template.

Reviewed By: simoll

Differential Revision: https://reviews.llvm.org/D122032

llvm/include/llvm/IR/VectorBuilder.h

index a24338a..301edae 100644 (file)
@@ -36,7 +36,7 @@ public:
   };
 
 private:
-  IRBuilder<> &Builder;
+  IRBuilderBase &Builder;
   Behavior ErrorHandling;
 
   // Explicit mask parameter.
@@ -58,7 +58,7 @@ private:
   }
 
 public:
-  VectorBuilder(IRBuilder<> &Builder,
+  VectorBuilder(IRBuilderBase &Builder,
                 Behavior ErrorHandling = Behavior::ReportAndAbort)
       : Builder(Builder), ErrorHandling(ErrorHandling), Mask(nullptr),
         ExplicitVectorLength(nullptr),