-
Notifications
You must be signed in to change notification settings - Fork 379
Open
Description
While compiling the detr-DocLayNet model , zDLC compilation fails with failed to legalize operation 'onnx.GridSample'
podman run --rm -v ${ZDLC_MODEL_DIR}:/workdir:z ${ZDLC_IMAGE} --EmitLib --O3 --onnx-op-stats=JSON -march=z17 --mtriple=s390x-ibm-loz ${ZDLC_MODEL_NAME}.onnx
[1/6] Mon Aug 18 13:18:55 2025 (0s) Importing ONNX Model to MLIR Module from "detr_doclayout.onnx"
[2/6] Mon Aug 18 13:18:56 2025 (1s) Compiling and Optimizing MLIR Module
failed to legalize operation 'onnx.GridSample'
{
"func.func" : 1,
"func.return" : 1,
"onnx.Add" : 406,
"onnx.And" : 1,
"onnx.Cast" : 106,
"onnx.Clip" : 33,
"onnx.Concat" : 549,
"onnx.Constant" : 1695,
"onnx.Conv" : 21,
"onnx.Cos" : 9,
"onnx.CumSum" : 8,
"onnx.Dim" : 486,
"onnx.Div" : 77,
"onnx.Expand" : 26,
"onnx.Flatten" : 4,
"onnx.Gather" : 102,
"onnx.GatherElements" : 1,
"onnx.Greater" : 2,
"onnx.GridSample" : 48,
"onnx.LayerNormalization" : 36,
"onnx.Less" : 1,
"onnx.Log" : 12,
"onnx.MatMul" : 192,
"onnx.MaxPoolSingleOut" : 1,
"onnx.Mul" : 161,
"onnx.NoValue" : 1,
"onnx.Not" : 13,
"onnx.Range" : 16,
"onnx.ReduceSum" : 29,
"onnx.Relu" : 87,
"onnx.Reshape" : 409,
"onnx.Resize" : 4,
"onnx.Sigmoid" : 13,
"onnx.Sin" : 9,
"onnx.Slice" : 138,
"onnx.Softmax" : 18,
"onnx.Split" : 1,
"onnx.Squeeze" : 34,
"onnx.Sub" : 12,
"onnx.Tile" : 1,
"onnx.TopK" : 1,
"onnx.Transpose" : 162,
"onnx.Unsqueeze" : 306,
"onnx.Where" : 16
}
But the same when ran with--EmitONNXIR is not failing.
podman run --rm -v ${ZDLC_MODEL_DIR}:/workdir:z ${ZDLC_IMAGE} --EmitONNXIR --O3 --onnx-op-stats=JSON -march=z17 --mtriple=s390x-ibm-loz ${ZDLC_MODEL_NAME}.onnx
Warning: --onnx-op-stats requires targets like --EmitMLIR, --EmitLLVMIR, or binary-generating emit commands.
[1/3] Mon Aug 18 13:54:04 2025 (0s) Importing ONNX Model to MLIR Module from "detr_doclayout.onnx"
[2/3] Mon Aug 18 13:54:05 2025 (1s) Compiling and Optimizing MLIR Module
[3/3] Mon Aug 18 13:54:06 2025 (2s) Compilation completed
Metadata
Metadata
Assignees
Labels
No labels