Skip to content

Commit f56ab9b

Browse files
committed
[MLIR][pass registry] show overlapping pass
1 parent 23d6a6d commit f56ab9b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

mlir/lib/Pass/PassRegistry.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,10 @@ void mlir::registerPassPipeline(
9999
PassPipelineInfo pipelineInfo(arg, description, function,
100100
std::move(optHandler));
101101
bool inserted = passPipelineRegistry->try_emplace(arg, pipelineInfo).second;
102-
assert(inserted && "Pass pipeline registered multiple times");
102+
#ifndef NDEBUG
103+
if (!inserted)
104+
report_fatal_error("Pass pipeline " + arg + " registered multiple times");
105+
#endif
103106
(void)inserted;
104107
}
105108

0 commit comments

Comments
 (0)