[Mlir-commits] [mlir] 67205f9 - Remove `-action` suffix from the tag defining an Action: it is redundant here

Mehdi Amini llvmlistbot at llvm.org
Sun Apr 23 22:23:54 PDT 2023


Author: Mehdi Amini
Date: 2023-04-23T23:06:27-06:00
New Revision: 67205f907a1fb40eeeaa519920b6d95646f65d8e

URL: https://github.com/llvm/llvm-project/commit/67205f907a1fb40eeeaa519920b6d95646f65d8e
DIFF: https://github.com/llvm/llvm-project/commit/67205f907a1fb40eeeaa519920b6d95646f65d8e.diff

LOG: Remove `-action` suffix from the tag defining an Action: it is redundant here

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

Added: 
    

Modified: 
    mlir/include/mlir/Rewrite/PatternApplicator.h
    mlir/lib/Pass/PassDetail.h
    mlir/test/Pass/action-logging-filter.mlir
    mlir/test/Pass/action-logging.mlir

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir/Rewrite/PatternApplicator.h b/mlir/include/mlir/Rewrite/PatternApplicator.h
index 41ec95afcd9bd..0bdc00c363d20 100644
--- a/mlir/include/mlir/Rewrite/PatternApplicator.h
+++ b/mlir/include/mlir/Rewrite/PatternApplicator.h
@@ -32,7 +32,7 @@ class ApplyPatternAction : public tracing::ActionImpl<ApplyPatternAction> {
   using Base = tracing::ActionImpl<ApplyPatternAction>;
   ApplyPatternAction(ArrayRef<IRUnit> irUnits, const Pattern &pattern)
       : Base(irUnits), pattern(pattern) {}
-  static constexpr StringLiteral tag = "apply-pattern-action";
+  static constexpr StringLiteral tag = "apply-pattern";
   static constexpr StringLiteral desc =
       "Encapsulate the application of rewrite patterns";
 

diff  --git a/mlir/lib/Pass/PassDetail.h b/mlir/lib/Pass/PassDetail.h
index ca60cf2fa5894..35f1edd8b0e2a 100644
--- a/mlir/lib/Pass/PassDetail.h
+++ b/mlir/lib/Pass/PassDetail.h
@@ -21,7 +21,7 @@ struct PassExecutionAction : public tracing::ActionImpl<PassExecutionAction> {
   using Base = tracing::ActionImpl<PassExecutionAction>;
   PassExecutionAction(ArrayRef<IRUnit> irUnits, const Pass &pass)
       : Base(irUnits), pass(pass) {}
-  static constexpr StringLiteral tag = "pass-execution-action";
+  static constexpr StringLiteral tag = "pass-execution";
   void print(raw_ostream &os) const override;
   const Pass &getPass() const { return pass; }
   Operation *getOp() const {

diff  --git a/mlir/test/Pass/action-logging-filter.mlir b/mlir/test/Pass/action-logging-filter.mlir
index e565b18d1ce13..c853a08b57a4b 100644
--- a/mlir/test/Pass/action-logging-filter.mlir
+++ b/mlir/test/Pass/action-logging-filter.mlir
@@ -20,12 +20,12 @@ func.func @c() {
 // Specify the current file as filter, expect to see all actions.
 // RUN: mlir-opt %s --log-mlir-actions-filter=%s --log-actions-to=- -pass-pipeline="builtin.module(func.func(canonicalize))" -o %t --mlir-disable-threading | FileCheck %s
 
-// CHECK: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @a() {...}
-// CHECK-NEXT: [thread {{.*}}] completed `pass-execution-action`
-// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @b() {...}
-// CHECK-NEXT: [thread {{.*}}] completed `pass-execution-action`
-// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @c() {...}
-// CHECK-NEXT: [thread {{.*}}] completed `pass-execution-action`
+// CHECK: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @a() {...}
+// CHECK-NEXT: [thread {{.*}}] completed `pass-execution`
+// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @b() {...}
+// CHECK-NEXT: [thread {{.*}}] completed `pass-execution`
+// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @c() {...}
+// CHECK-NEXT: [thread {{.*}}] completed `pass-execution`
 
 ////////////////////////////////////
 /// 2. No match
@@ -46,15 +46,15 @@ func.func @c() {
 
 // CHECK-SECOND-NOT: @a
 // CHECK-SECOND-NOT: @c
-// CHECK-SECOND: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @b() {...}
-// CHECK-SECOND-NEXT: [thread {{.*}}] completed `pass-execution-action`
+// CHECK-SECOND: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @b() {...}
+// CHECK-SECOND-NEXT: [thread {{.*}}] completed `pass-execution`
 
 // Filter the first and third functions
 // RUN: mlir-opt %s --log-mlir-actions-filter=%s:4,%s:12 --log-actions-to=- -pass-pipeline="builtin.module(func.func(canonicalize))" -o %t --mlir-disable-threading | FileCheck %s  --check-prefix=CHECK-FIRST-THIRD
 
 // CHECK-FIRST-THIRD-NOT: Canonicalizer
-// CHECK-FIRST-THIRD: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @a() {...}
-// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] completed `pass-execution-action`
-// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `Canonicalizer` on Operation `func.func` (func.func @c() {...}
-// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] completed `pass-execution-action`
+// CHECK-FIRST-THIRD: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @a() {...}
+// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] completed `pass-execution`
+// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `Canonicalizer` on Operation `func.func` (func.func @c() {...}
+// CHECK-FIRST-THIRD-NEXT: [thread {{.*}}] completed `pass-execution`
 // CHECK-FIRST-THIRD-NOT: Canonicalizer

diff  --git a/mlir/test/Pass/action-logging.mlir b/mlir/test/Pass/action-logging.mlir
index d10c64c2af2ed..5ceb7ebae96bc 100644
--- a/mlir/test/Pass/action-logging.mlir
+++ b/mlir/test/Pass/action-logging.mlir
@@ -1,7 +1,7 @@
 // RUN: mlir-opt %s --log-actions-to=- -canonicalize -test-module-pass | FileCheck %s
 
-// CHECK: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action` running `Canonicalizer` on Operation `builtin.module` (module {...}
-// CHECK-NEXT: [thread {{.*}}] completed `pass-execution-action`
-// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution-action`  running `{{.*}}TestModulePass` on Operation `builtin.module` (module {...}
-// CHECK-NEXT: [thread {{.*}}] completed `pass-execution-action`
+// CHECK: [thread {{.*}}] begins (no breakpoint) Action `pass-execution` running `Canonicalizer` on Operation `builtin.module` (module {...}
+// CHECK-NEXT: [thread {{.*}}] completed `pass-execution`
+// CHECK-NEXT: [thread {{.*}}] begins (no breakpoint) Action `pass-execution`  running `{{.*}}TestModulePass` on Operation `builtin.module` (module {...}
+// CHECK-NEXT: [thread {{.*}}] completed `pass-execution`
 // CHECK-NOT: Action


        


More information about the Mlir-commits mailing list