@@ -162,6 +162,7 @@ module attributes {"ttg.num-ctas" = 1 : i32, "ttg.num-warps" = 8 : i32, "ttg.thr
162
162
163
163
// -----
164
164
165
+ // COM: A operand mismatch
165
166
#dpas = #ttig.dpas <{repeatCount = 8 , systolicDepth = 8 , executionSize = 16 , opsPerChan = 2 , threadsPerWarp = 16 , warpsPerCTA = [2 , 2 ], repCluster = [1 , 1 ]}>
166
167
#dot_operand_a = #ttg.dot_op <{opIdx =0 , parent =#dpas , kWidth =1 }>
167
168
#dot_operand_b = #ttg.dot_op <{opIdx =1 , parent =#dpas , kWidth =2 }>
@@ -181,6 +182,26 @@ module attributes {"ttg.num-ctas" = 1 : i32, "ttg.num-warps" = 4 : i32} {
181
182
182
183
// -----
183
184
185
+ // COM: B operand mismatch
186
+ #dpas = #ttig.dpas <{repeatCount = 8 , systolicDepth = 8 , executionSize = 16 , opsPerChan = 2 , threadsPerWarp = 16 , warpsPerCTA = [2 , 2 ], repCluster = [1 , 1 ]}>
187
+ #dot_operand_a = #ttg.dot_op <{opIdx =0 , parent =#dpas , kWidth =1 }>
188
+ #dot_operand_b = #ttg.dot_op <{opIdx =1 , parent =#dpas , kWidth =2 }>
189
+ #smem = #ttg.shared_memory
190
+ module attributes {" ttg.num-ctas" = 1 : i32 , " ttg.num-warps" = 4 : i32 } {
191
+ // CHECK-LABEL: matmul_tf32dot
192
+ tt.func @matmul_tf32dot (%ptr: !tt.ptr <f32 >,
193
+ %a_mat:tensor <32 x16 xf16 , #dot_operand_a >, %b_mat:tensor <16 x32 xf32 , #dot_operand_b >) {
194
+ %cst = arith.constant dense <0.000000e+00 > : tensor <32 x32 xf32 , #dpas >
195
+
196
+ // expected-error @+1 {{Layout has opsPerChannel = 2 but tensor element type is 'f32'. Expected 16 bit type.}}
197
+ %28 = tt.dot %a_mat , %b_mat , %cst , inputPrecision = tf32 : tensor <32 x16 xf16 , #dot_operand_a > * tensor <16 x32 xf32 , #dot_operand_b > -> tensor <32 x32 xf32 , #dpas >
198
+
199
+ tt.return
200
+ }
201
+ }
202
+
203
+ // -----
204
+
184
205
#dpas = #ttig.dpas <{repeatCount = 8 , systolicDepth = 8 , executionSize = 16 , opsPerChan = 1 , threadsPerWarp = 16 , warpsPerCTA = [2 , 2 ], repCluster = [1 , 1 ]}>
185
206
#dot_operand_a = #ttg.dot_op <{opIdx =0 , parent =#dpas , kWidth =1 }>
186
207
// expected-error @below {{ttg.dot_op kWidth parameter must match the parent's opsPerChannel}}
0 commit comments