File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed
mlir/lib/Dialect/XeGPU/IR Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -298,17 +298,10 @@ LogicalResult TensorDescType::verify(
298298 " contiguous elements" ;
299299 }
300300
301- // For 1D tensor, pad the shape with an outer unit dimension to allow common
302- // validation logic.
303- SmallVector<int64_t > tensorShape (shape);
304- if (rank == 1 )
305- tensorShape = {1 , tensorShape.back ()};
306-
307- size_t dims = tensorShape.size ();
308- for (size_t i = 0 ; i < dims; ++i) {
301+ for (size_t i = 0 ; i < shape.size (); ++i) {
309302 uint32_t numElemPerWi = laneLayout[i] * laneData[i];
310- if (tensorShape [i] < numElemPerWi || tensorShape [i] % numElemPerWi != 0 )
311- return emitError () << " cannot distribute " << tensorShape [i] << " over "
303+ if (shape [i] < numElemPerWi || shape [i] % numElemPerWi != 0 )
304+ return emitError () << " cannot distribute " << shape [i] << " over "
312305 << laneLayout[i] << " work items with "
313306 << laneData[i] << " elements each" ;
314307 }
You can’t perform that action at this time.
0 commit comments