[mlir][StorageUniquer] Fix build with LLVM_ENABLE_THREADS=OFF
authorAlexandre Ganea <alex_toresh@yahoo.fr>
Sun, 2 Apr 2023 15:38:58 +0000 (11:38 -0400)
committerAlexandre Ganea <alex_toresh@yahoo.fr>
Sun, 2 Apr 2023 15:38:58 +0000 (11:38 -0400)
mlir/lib/Support/StorageUniquer.cpp

index f670318..2e9b17e 100644 (file)
@@ -223,7 +223,7 @@ private:
   BaseStorage *
   getOrCreate(bool threadingIsEnabled, unsigned hashValue,
               function_ref<bool(const BaseStorage *)> isEqual,
-              function_ref<BaseStorage *(StorageAllocator &)> ctorFn) {
+              function_ref<BaseStorage *()> ctorFn) {
     ParametricStorageUniquer::LookupKey lookupKey{hashValue, isEqual};
     return getOrCreateUnsafe(shard, lookupKey, ctorFn);
   }
@@ -231,8 +231,8 @@ private:
   /// way.
   LogicalResult
   mutate(bool threadingIsEnabled, BaseStorage *storage,
-         function_ref<LogicalResult(StorageAllocator &)> mutationFn) {
-    return mutationFn(shard.allocator);
+         function_ref<LogicalResult()> mutationFn) {
+    return mutationFn();
   }
 
 private: