[Mlir-commits] [mlir] 6a291ed - [mlir] Remove unnecessary copying of pass options

Christian Sigg llvmlistbot at llvm.org
Wed Mar 10 12:55:34 PST 2021


Author: Christian Sigg
Date: 2021-03-10T21:55:28+01:00
New Revision: 6a291ed0f069a1886705bd4a814dad2e8eb8307c

URL: https://github.com/llvm/llvm-project/commit/6a291ed0f069a1886705bd4a814dad2e8eb8307c
DIFF: https://github.com/llvm/llvm-project/commit/6a291ed0f069a1886705bd4a814dad2e8eb8307c.diff

LOG: [mlir] Remove unnecessary copying of pass options

I missed a comment in D98279 that you don't need to copy pass options.

Reviewed By: rriddle

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

Added: 
    

Modified: 
    mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp b/mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp
index b6e3c7082024..06c2c508d5ad 100644
--- a/mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp
+++ b/mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp
@@ -27,13 +27,7 @@ gpu::SerializeToBlobPass::SerializeToBlobPass(TypeID passID)
     : OperationPass<gpu::GPUModuleOp>(passID) {}
 
 gpu::SerializeToBlobPass::SerializeToBlobPass(const SerializeToBlobPass &other)
-    : OperationPass<gpu::GPUModuleOp>(other) {
-  // Pass::Option has no copy constructor, copy them manually.
-  triple = other.triple;
-  chip = other.chip;
-  features = other.features;
-  gpuBinaryAnnotation = other.gpuBinaryAnnotation;
-}
+    : OperationPass<gpu::GPUModuleOp>(other) {}
 
 static std::string translateToISA(llvm::Module &llvmModule,
                                   llvm::TargetMachine &targetMachine) {


        


More information about the Mlir-commits mailing list