[Integrate] Update torch-mlir to f843f738 (#25196) Updates torch-mlir from its October 29 upstream baseline to [`llvm/torch-mlir@f843f738`](https://github.com/llvm/torch-mlir/commit/f843f7386b422477a1570307fa5e5c12527193e0), using [`iree-org/torch-mlir@68244564`](https://github.com/iree-org/torch-mlir/commit/68244564a58e6eb48f15460dff217c135da631f6) (`sm-iree-integrates/torch-20261104`) adapted to IREE's current LLVM revision. On top of canonical torch-mlir, the integration branch carries only the LLVM submodule bump, now pointing at IREE's current LLVM and StableHLO pins. The previous pin carried no other adaptation patches, so none were dropped. The PT2E quantize/dequantize verifier from llvm/torch-mlir#4848 rejects an out-of-range per-channel axis and a group size that does not divide the last input dimension. `@out_of_range_axis` and `@indivisible_group_size` in `quantization_to_linalg_ext.mlir` built such IR and are removed. ONNX op test expectations: no changes in the CPU or GPU configs. Assisted by: Claude Signed-off-by: Roberto Laudani <laudani@roofline.ai>
diff --git a/compiler/plugins/input/Torch/InputConversion/test/quantization_to_linalg_ext.mlir b/compiler/plugins/input/Torch/InputConversion/test/quantization_to_linalg_ext.mlir index 0a3de28..32cf41b 100644 --- a/compiler/plugins/input/Torch/InputConversion/test/quantization_to_linalg_ext.mlir +++ b/compiler/plugins/input/Torch/InputConversion/test/quantization_to_linalg_ext.mlir
@@ -270,55 +270,6 @@ // ----- -// An axis outside the input rank cannot index the parameter maps, so the op is -// left for the Torch-to-Linalg lowering. -// CHECK-LABEL: func.func @out_of_range_axis( -// CHECK: torch.quantized_decomposed.dequantize_per_channel -// CHECK-NOT: iree_linalg_ext.dequantize_affine -func.func @out_of_range_axis( - %input: !torch.vtensor<[4,8],si8>, - %scales: !torch.vtensor<[4],f32>) -> !torch.vtensor<[4,8],f32> { - %axis = torch.constant.int 2 - %minimum = torch.constant.int -128 - %maximum = torch.constant.int 127 - %dtype = torch.constant.int 1 - %none = torch.constant.none - %out_dtype = torch.derefine %none : !torch.none to !torch.optional<int> - %result = torch.quantized_decomposed.dequantize_per_channel - %input, %scales, %none, %axis, %minimum, %maximum, %dtype, %out_dtype - : !torch.vtensor<[4,8],si8>, !torch.vtensor<[4],f32>, !torch.none, - !torch.int, !torch.int, !torch.int, !torch.int, !torch.optional<int> - -> !torch.vtensor<[4,8],f32> - return %result : !torch.vtensor<[4,8],f32> -} - -// ----- - -// A group size that does not divide the last dimension cannot split the input -// into groups, so the op is left for the Torch-to-Linalg lowering. -// CHECK-LABEL: func.func @indivisible_group_size( -// CHECK: torch.quantized_decomposed.dequantize_per_channel_group -// CHECK-NOT: iree_linalg_ext.dequantize_affine -func.func @indivisible_group_size( - %input: !torch.vtensor<[4,8],si8>, - %scales: !torch.vtensor<[4,2],f32>) -> !torch.vtensor<[4,8],f32> { - %minimum = torch.constant.int -128 - %maximum = torch.constant.int 127 - %dtype = torch.constant.int 1 - %group_size = torch.constant.int 3 - %none = torch.constant.none - %out_dtype = torch.constant.int 6 - %result = torch.quantized_decomposed.dequantize_per_channel_group - %input, %scales, %none, %minimum, %maximum, %dtype, %group_size, - %out_dtype - : !torch.vtensor<[4,8],si8>, !torch.vtensor<[4,2],f32>, !torch.none, - !torch.int, !torch.int, !torch.int, !torch.int, !torch.int - -> !torch.vtensor<[4,8],f32> - return %result : !torch.vtensor<[4,8],f32> -} - -// ----- - // LinalgExt storage is a signless integer, so fp8 storage is left for the // Torch-to-Linalg lowering. // CHECK-LABEL: func.func @float_storage(
diff --git a/third_party/torch-mlir b/third_party/torch-mlir index 08a7725..6824456 160000 --- a/third_party/torch-mlir +++ b/third_party/torch-mlir
@@ -1 +1 @@ -Subproject commit 08a772545eb3cdb4f95961fe08d18d3a0632932a +Subproject commit 68244564a58e6eb48f15460dff217c135da631f6