Skip to content

Commit 5ece211

Browse files
committed
[MLIR] Work around an ICE in GCC 7.
Looks like we have a blind spot in the testing matrix. AsyncRegionRewriter.cpp: In member function ‘virtual void {anonymous}::GpuAsyncRegionPass::runOnFunction()’: AsyncRegionRewriter.cpp:113:16: internal compiler error: in replace_placeholders_r, at cp/tree.c:2804 if (getFunction() ~~~~~~~~~~~~~ .getRegion() ~~~~~~~~~~~~ .walk(Callback{OpBuilder{&getContext()}}) ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 parent c254b0b commit 5ece211

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

mlir/lib/Dialect/GPU/Transforms/AsyncRegionRewriter.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,8 @@ struct GpuAsyncRegionPass::Callback {
108108
// inserts the necessary synchronization (as gpu.wait ops). Assumes sequential
109109
// execution semantics and that no GPU ops are asynchronous yet.
110110
void GpuAsyncRegionPass::runOnFunction() {
111-
if (getFunction()
112-
.getRegion()
113-
.walk(Callback{OpBuilder(&getContext())})
114-
.wasInterrupted())
111+
Callback callback{OpBuilder(&getContext())};
112+
if (getFunction().getRegion().walk(callback).wasInterrupted())
115113
return signalPassFailure();
116114
}
117115

0 commit comments

Comments
 (0)