Skip to content

Commit c720c6b

Browse files
committed
Fix vec slice replacement?
1 parent 393ef36 commit c720c6b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mlir/lib/Dialect/SPIRV/Transforms/SPIRVConversion.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1038,7 +1038,7 @@ struct FuncOpVectorUnroll final : OpRewritePattern<func::FuncOp> {
10381038
// Since all newly created operations are in the beginning, reaching the
10391039
// end of them means that any later `vector.insert_strided_slice` should
10401040
// not be touched.
1041-
if (op->getBlock() == &entryBlock &&
1041+
if (op->getBlock() != &entryBlock ||
10421042
static_cast<size_t>(std::distance(entryBlock.begin(),
10431043
op->getIterator())) >= newOpCount)
10441044
return;

0 commit comments

Comments
 (0)