CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
154 lines
6.4 KiB
MLIR
154 lines
6.4 KiB
MLIR
// RUN: mlir-opt %s -split-input-file -verify-diagnostics
|
|
|
|
// -----
|
|
|
|
func.func @a_is_2d(%a : vector<2x2xi32>, %b : vector<4x4xi8>) -> vector<2x2xi32> {
|
|
// expected-error@+1 {{operand `a` should be 1-dimensional}}
|
|
%0 = arm_neon.2d.sdot %a, %b, %b : vector<4x4xi8>, vector<4x4xi8> to vector<2x2xi32>
|
|
return %0 : vector<2x2xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @b_is_3d(%a : vector<4xi32>, %b : vector<1x4x4xi8>) -> vector<4xi32> {
|
|
// expected-error@+1 {{operand `b` should be 2-dimensional}}
|
|
%0 = arm_neon.2d.sdot %a, %b, %b : vector<1x4x4xi8>, vector<1x4x4xi8> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @b_has_2_columns(%a : vector<4xi32>, %b : vector<4x2xi8>) -> vector<4xi32> {
|
|
// expected-error@+1 {{operand `b` should have 4 columns}}
|
|
%0 = arm_neon.2d.sdot %a, %b, %b : vector<4x2xi8>, vector<4x2xi8> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @b_has_2_rows_but_a_has_length_4(%a : vector<4xi32>, %b : vector<2x4xi8>) -> vector<4xi32> {
|
|
// expected-error@+1 {{operand `b` should have as many rows as the size of operand `a`}}
|
|
%0 = arm_neon.2d.sdot %a, %b, %b : vector<2x4xi8>, vector<2x4xi8> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @smmla_invalid_input_types(%a: vector<4xi32>,
|
|
%b: vector<16xi4>,
|
|
%c: vector<16xi4>) -> vector<4xi32> {
|
|
// expected-error@+1 {{op operand #1 must be a vector with length 16 of 8-bit signless integer values, but got 'vector<16xi4>'}}
|
|
%0 = arm_neon.intr.smmla %a, %b, %c : vector<16xi4> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @smmla_invalid_dimensions(%a: vector<8xi32>,
|
|
%b: vector<32xi8>,
|
|
%c: vector<32xi8>) -> vector<8xi32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit signless integer values, but got 'vector<8xi32>'}}
|
|
%0 = arm_neon.intr.smmla %a, %b, %c : vector<32xi8> to vector<8xi32>
|
|
return %0 : vector<8xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @ummla_invalid_input_types(%a: vector<4xi32>,
|
|
%b: vector<16xi4>,
|
|
%c: vector<16xi4>) -> vector<4xi32> {
|
|
// expected-error@+1 {{op operand #1 must be a vector with length 16 of 8-bit signless integer values, but got 'vector<16xi4>'}}
|
|
%0 = arm_neon.intr.ummla %a, %b, %c : vector<16xi4> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @ummla_invalid_dimensions(%a: vector<8xi32>,
|
|
%b: vector<32xi8>,
|
|
%c: vector<32xi8>) -> vector<8xi32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit signless integer values, but got 'vector<8xi32>'}}
|
|
%0 = arm_neon.intr.ummla %a, %b, %c : vector<32xi8> to vector<8xi32>
|
|
return %0 : vector<8xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @usmmla_invalid_input_types(%a: vector<4xi32>,
|
|
%b: vector<16xi4>,
|
|
%c: vector<16xi4>) -> vector<4xi32> {
|
|
// expected-error@+1 {{op operand #1 must be a vector with length 16 of 8-bit signless integer values, but got 'vector<16xi4>'}}
|
|
%0 = arm_neon.intr.usmmla %a, %b, %c : vector<16xi4> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @usmmla_invalid_dimensions(%a: vector<8xi32>,
|
|
%b: vector<32xi8>,
|
|
%c: vector<32xi8>) -> vector<8xi32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit signless integer values, but got 'vector<8xi32>'}}
|
|
%0 = arm_neon.intr.usmmla %a, %b, %c : vector<32xi8> to vector<8xi32>
|
|
return %0 : vector<8xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_invalid_element_type_lhs_rhs(%acc: vector<4xf32>,
|
|
%lhs: vector<8xf16>,
|
|
%rhs: vector<8xf16>) -> vector<4xf32> {
|
|
// expected-error@+1 {{operand #1 must be a vector with length 8 of bfloat16 type values, but got 'vector<8xf16>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<8xf16> to vector<4xf32>
|
|
return %0 : vector<4xf32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_invalid_dimension_lhs_rhs(%acc: vector<4xf32>,
|
|
%lhs: vector<4xbf16>,
|
|
%rhs: vector<4xbf16>) -> vector<4xf32> {
|
|
// expected-error@+1 {{operand #1 must be a vector with length 8 of bfloat16 type values, but got 'vector<4xbf16>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<4xbf16> to vector<4xf32>
|
|
return %0 : vector<4xf32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_scalable_dimension_lhs_rhs(%acc: vector<4xf32>,
|
|
%lhs: vector<[8]xbf16>,
|
|
%rhs: vector<[8]xbf16>) -> vector<4xf32> {
|
|
// expected-error@+1 {{operand #1 must be a vector with length 8 of bfloat16 type values, but got 'vector<[8]xbf16>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<[8]xbf16> to vector<4xf32>
|
|
return %0 : vector<4xf32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_invalid_element_type_acc(%acc: vector<4xi32>,
|
|
%lhs: vector<8xbf16>,
|
|
%rhs: vector<8xbf16>) -> vector<4xi32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit float values, but got 'vector<4xi32>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<8xbf16> to vector<4xi32>
|
|
return %0 : vector<4xi32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_invalid_dimension_acc(%acc: vector<8xf32>,
|
|
%lhs: vector<8xbf16>,
|
|
%rhs: vector<8xbf16>) -> vector<8xf32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit float values, but got 'vector<8xf32>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<8xbf16> to vector<8xf32>
|
|
return %0 : vector<8xf32>
|
|
}
|
|
|
|
// -----
|
|
|
|
func.func @bfmmla_scalable_dimension_acc(%acc: vector<[4]xf32>,
|
|
%lhs: vector<8xbf16>,
|
|
%rhs: vector<8xbf16>) -> vector<[4]xf32> {
|
|
// expected-error@+1 {{op operand #0 must be a vector with length 4 of 32-bit float values, but got 'vector<[4]xf32>'}}
|
|
%0 = arm_neon.intr.bfmmla %acc, %lhs, %rhs : vector<8xbf16> to vector<[4]xf32>
|
|
return %0 : vector<[4]xf32>
|
|
}
|