Skip to content

Commit c41b8b3

Browse files
committed
Fix test
1 parent c240c78 commit c41b8b3

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

mlir/test/Dialect/XeGPU/xegpu-unroll-patterns.mlir

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -214,9 +214,9 @@ gpu.module @test {
214214

215215

216216
// CHECK-LABEL: load_with_offsets
217-
// CHECK-SAME: [[arg0:%.+]]: memref<64xf32>
218-
// CHECK-COUNT-2: xegpu.load {{.*}}[{{.*}}], {{.*}} <{chunk_size = 1 : i64, l1_hint = #xegpu.cache_hint<cached>}> : memref<64xf32>, vector<16xindex>, vector<16xi1> -> vector<16xf32>
219-
gpu.func @load_with_offsets(%src: memref<64xf32>) -> vector<32xf32> {
217+
// CHECK-SAME: [[arg0:%.+]]: ui64
218+
// CHECK-COUNT-2: xegpu.load {{.*}}[{{.*}}], {{.*}} <{chunk_size = 1 : i64, l1_hint = #xegpu.cache_hint<cached>}> : ui64, vector<16xindex>, vector<16xi1> -> vector<16xf32>
219+
gpu.func @load_with_offsets(%src: ui64) -> vector<32xf32> {
220220
%cst = arith.constant dense<[
221221
0, 8, 16, 24, 32, 40, 48, 56,
222222
64, 72, 80, 88, 96, 104, 112, 120,
@@ -226,7 +226,7 @@ gpu.module @test {
226226

227227
%c17 = arith.constant 17: index
228228
%mask = vector.create_mask %c17: vector<32xi1>
229-
%ld = xegpu.load %src[%cst], %mask {chunk_size = 1, layout_result_0 = #xegpu.layout<inst_data = [16]>, l1_hint = #xegpu.cache_hint<cached>} : memref<64xf32>, vector<32xindex>, vector<32xi1> -> vector<32xf32>
229+
%ld = xegpu.load %src[%cst], %mask {chunk_size = 1, layout_result_0 = #xegpu.layout<inst_data = [16]>, l1_hint = #xegpu.cache_hint<cached>} : ui64, vector<32xindex>, vector<32xi1> -> vector<32xf32>
230230

231231
gpu.return %ld : vector<32xf32>
232232
}
@@ -279,9 +279,9 @@ gpu.module @test {
279279
//-----
280280

281281
// CHECK-LABEL: store_with_offsets
282-
// CHECK-SAME: [[arg0:%.+]]: memref<64xf32>
283-
// CHECK-COUNT-2: xegpu.store {{.*}}[{{.*}}], {{.*}} <{chunk_size = 1 : i64, l1_hint = #xegpu.cache_hint<cached>}> : vector<16xf32>, memref<64xf32>, vector<16xindex>, vector<16xi1>
284-
gpu.func @store_with_offsets(%src: memref<64xf32>) {
282+
// CHECK-SAME: [[arg0:%.+]]: ui64
283+
// CHECK-COUNT-2: xegpu.store {{.*}}[{{.*}}], {{.*}} <{chunk_size = 1 : i64, l1_hint = #xegpu.cache_hint<cached>}> : vector<16xf32>, ui64, vector<16xindex>, vector<16xi1>
284+
gpu.func @store_with_offsets(%src: ui64) {
285285
%cst = arith.constant dense<[
286286
0, 8, 16, 24, 32, 40, 48, 56,
287287
64, 72, 80, 88, 96, 104, 112, 120,
@@ -293,7 +293,7 @@ gpu.module @test {
293293
%mask = vector.create_mask %c17: vector<32xi1>
294294

295295
%st_vec = arith.constant dense<1023.0>: vector<32xf32>
296-
xegpu.store %st_vec, %src[%cst], %mask {chunk_size = 1, layout = #xegpu.layout<inst_data = [16]>, l1_hint = #xegpu.cache_hint<cached>} : vector<32xf32>, memref<64xf32>, vector<32xindex>, vector<32xi1>
296+
xegpu.store %st_vec, %src[%cst], %mask {chunk_size = 1, layout = #xegpu.layout<inst_data = [16]>, l1_hint = #xegpu.cache_hint<cached>} : vector<32xf32>, ui64, vector<32xindex>, vector<32xi1>
297297

298298
gpu.return
299299
}
@@ -364,14 +364,14 @@ gpu.module @test {
364364

365365
//-----
366366
// CHECK-LABEL: load_with_offsets_chunk
367-
// CHECK-SAME: [[arg0:%.+]]: memref<64xf32>
367+
// CHECK-SAME: [[arg0:%.+]]: ui64
368368
// CHECK: [[cst:%.+]] = arith.constant dense<0.000000e+00> : vector<32x4xf32>
369369
// CHECK: [[cst0:%.+]] = arith.constant dense<[130, 138, 146, 154, 162, 170, 178, 186, 194, 202, 210, 218, 226, 234, 242, 250]> : vector<16xindex>
370370
// CHECK: [[cst1:%.+]] = arith.constant dense<[2, 10, 18, 26, 34, 42, 50, 58, 66, 74, 82, 90, 98, 106, 114, 122]> : vector<16xindex>
371371
// CHECK: [[cst2:%.+]] = arith.constant dense<[128, 136, 144, 152, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248]> : vector<16xindex>
372372
// CHECK: [[cst3:%.+]] = arith.constant dense<[0, 8, 16, 24, 32, 40, 48, 56, 64, 72, 80, 88, 96, 104, 112, 120]> : vector<16xindex>
373-
// CHECK-COUNT-4: xegpu.load {{.*}}[{{.*}}], {{.*}} <{chunk_size = 2 : i64, l1_hint = #xegpu.cache_hint<cached>}> : memref<64xf32>, vector<16xindex>, vector<16xi1> -> vector<16x2xf32>
374-
gpu.func @load_with_offsets_chunk(%src: memref<64xf32>) -> vector<32x4xf32> {
373+
// CHECK-COUNT-4: xegpu.load {{.*}}[{{.*}}], {{.*}} <{chunk_size = 2 : i64, l1_hint = #xegpu.cache_hint<cached>}> : ui64, vector<16xindex>, vector<16xi1> -> vector<16x2xf32>
374+
gpu.func @load_with_offsets_chunk(%src: ui64) -> vector<32x4xf32> {
375375
%cst = arith.constant dense<[
376376
0, 8, 16, 24, 32, 40, 48, 56,
377377
64, 72, 80, 88, 96, 104, 112, 120,
@@ -381,7 +381,7 @@ gpu.module @test {
381381

382382
%c17 = arith.constant 17: index
383383
%mask = vector.create_mask %c17: vector<32xi1>
384-
%ld = xegpu.load %src[%cst], %mask {chunk_size = 4, layout_result_0 = #xegpu.layout<inst_data = [16, 2]>, l1_hint = #xegpu.cache_hint<cached>} : memref<64xf32>, vector<32xindex>, vector<32xi1> -> vector<32x4xf32>
384+
%ld = xegpu.load %src[%cst], %mask {chunk_size = 4, layout_result_0 = #xegpu.layout<inst_data = [16, 2]>, l1_hint = #xegpu.cache_hint<cached>} : ui64, vector<32xindex>, vector<32xi1> -> vector<32x4xf32>
385385
gpu.return %ld : vector<32x4xf32>
386386
}
387387

@@ -410,14 +410,14 @@ gpu.module @test {
410410

411411
//-----
412412
// CHECK-LABEL: store_with_offsets_chunk
413-
// CHECK-SAME: [[arg0:%.+]]: memref<64xf32>
413+
// CHECK-SAME: [[arg0:%.+]]: ui64
414414
// CHECK: [[cst:%.+]] = arith.constant dense<1.023000e+03> : vector<16x2xf32
415415
// CHECK: [[cst0:%.+]] = arith.constant dense<[130, 138, 146, 154, 162, 170, 178, 186, 194, 202, 210, 218, 226, 234, 242, 250]> : vector<16xindex>
416416
// CHECK: [[cst1:%.+]] = arith.constant dense<[2, 10, 18, 26, 34, 42, 50, 58, 66, 74, 82, 90, 98, 106, 114, 122]> : vector<16xindex>
417417
// CHECK: [[cst2:%.+]] = arith.constant dense<[128, 136, 144, 152, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248]> : vector<16xindex>
418418
// CHECK: [[cst3:%.+]] = arith.constant dense<[0, 8, 16, 24, 32, 40, 48, 56, 64, 72, 80, 88, 96, 104, 112, 120]> : vector<16xindex>
419-
// CHECK-COUNT-4: xegpu.store {{.*}}[{{.*}}], {{.*}} <{chunk_size = 2 : i64, l1_hint = #xegpu.cache_hint<cached>}> : vector<16x2xf32>, memref<64xf32>, vector<16xindex>, vector<16xi1>
420-
gpu.func @store_with_offsets_chunk(%src: memref<64xf32>) {
419+
// CHECK-COUNT-4: xegpu.store {{.*}}[{{.*}}], {{.*}} <{chunk_size = 2 : i64, l1_hint = #xegpu.cache_hint<cached>}> : vector<16x2xf32>, ui64, vector<16xindex>, vector<16xi1>
420+
gpu.func @store_with_offsets_chunk(%src: ui64) {
421421
%cst = arith.constant dense<[
422422
0, 8, 16, 24, 32, 40, 48, 56,
423423
64, 72, 80, 88, 96, 104, 112, 120,
@@ -429,7 +429,7 @@ gpu.module @test {
429429
%mask = vector.create_mask %c17: vector<32xi1>
430430

431431
%st_vec = arith.constant dense<1023.>: vector<32x4xf32>
432-
xegpu.store %st_vec, %src[%cst], %mask {chunk_size = 4, layout = #xegpu.layout<inst_data = [16, 2]>, l1_hint = #xegpu.cache_hint<cached>} : vector<32x4xf32>, memref<64xf32>, vector<32xindex>, vector<32xi1>
432+
xegpu.store %st_vec, %src[%cst], %mask {chunk_size = 4, layout = #xegpu.layout<inst_data = [16, 2]>, l1_hint = #xegpu.cache_hint<cached>} : vector<32x4xf32>, ui64, vector<32xindex>, vector<32xi1>
433433
gpu.return
434434
}
435435

0 commit comments

Comments
 (0)