@@ -330,12 +330,10 @@ gpu.module @test_distribution {
330330    //CHECK: [[l_off_x:%.+]] = index.mul [[id_x]], [[c32_1]] 
331331    //CHECK: [[c0:%.+]] = arith.constant 0 : index 
332332    //CHECK: [[c0_1:%.+]] = arith.constant 0 : index 
333-     //CHECK: [[l_off_y_0:%.+]] = arith.addi [[l_off_y]], [[c0]] : index 
334-     //CHECK: [[l_off_x_0:%.+]] = arith.addi [[l_off_x]], [[c0_1]] : index 
335333    //CHECK: [[c64:%.+]] = arith.constant 64 : index 
336-     //CHECK: [[off_y:%.+]] = index.remu [[l_off_y_0 ]], [[c64]] 
334+     //CHECK: [[off_y:%.+]] = index.remu [[l_off_y ]], [[c64]] 
337335    //CHECK: [[c128:%.+]] = arith.constant 128 : index 
338-     //CHECK: [[off_x:%.+]] = index.remu [[l_off_x_0 ]], [[c128]] 
336+     //CHECK: [[off_x:%.+]] = index.remu [[l_off_x ]], [[c128]] 
339337    //CHECK: xegpu.load_matrix [[mdesc]][[[off_y]], [[off_x]]] <{layout = #xegpu.layout<lane_layout = [2, 8], lane_data = [1, 1]>}>: !xegpu.mem_desc<64x128xf32>, index, index -> vector<32x32xf32> 
340338    %0  = xegpu.create_mem_desc  %arg0  : memref <32768 xi8 , 3 > -> !xegpu.mem_desc <64 x128 xf32 >
341339    %1  = xegpu.load_matrix  %0 [0 , 0 ] <{layout  = #xegpu.layout <sg_layout  = [2 , 4 ], sg_data  = [32 , 32 ], lane_layout  = [2 , 8 ], lane_data  = [1 , 1 ]>}>: !xegpu.mem_desc <64 x128 xf32 > -> vector <64 x128 xf32 >
@@ -354,13 +352,11 @@ gpu.module @test_distribution {
354352    //CHECK: [[id_y:%.+]] = affine.apply #map()[[[sgid]]] 
355353    //CHECK: [[id_x:%.+]] = affine.apply #map1()[[[sgid]]] 
356354    //CHECK: [[c32:%.+]] = arith.constant 32 : index 
357-     //CHECK: [[l_off_y_0 :%.+]] = index.mul [[id_y]], [[c32]] 
355+     //CHECK: [[l_off_y :%.+]] = index.mul [[id_y]], [[c32]] 
358356    //CHECK: [[c32_1:%.+]] = arith.constant 32 : index 
359-     //CHECK: [[l_off_x_0 :%.+]] = index.mul [[id_x]], [[c32_1]] 
357+     //CHECK: [[l_off_x :%.+]] = index.mul [[id_x]], [[c32_1]] 
360358    //CHECK: [[c0:%.+]] = arith.constant 0 : index 
361359    //CHECK: [[c0_2:%.+]] = arith.constant 0 : index 
362-     //CHECK: [[l_off_y:%.+]] = arith.addi [[l_off_y_0]], [[c0]] : index 
363-     //CHECK: [[l_off_x:%.+]] = arith.addi [[l_off_x_0]], [[c0_2]] : index 
364360    //CHECK: [[c64:%.+]] = arith.constant 64 : index 
365361    //CHECK: [[off_y:%.+]] = index.remu [[l_off_y]], [[c64]] 
366362    //CHECK: [[c128:%.+]] = arith.constant 128 : index 
@@ -417,11 +413,10 @@ gpu.module @test_distribution {
417413    //CHECK: [[sgId:%.+]] = gpu.subgroup_id : index 
418414    //CHECK-DAG: [[IDY:%.+]] = affine.apply #map2()[[[sgId]]] 
419415    //CHECK-DAG: [[c32:%.+]] = arith.constant 32 : index 
420-     //CHECK-DAG: [[LOCALY :%.+]] = index.mul [[IDY]], [[c32]] 
416+     //CHECK-DAG: [[LY :%.+]] = index.mul [[IDY]], [[c32]] 
421417    //CHECK-DAG: [[c0:%.+]] = arith.constant 0 : index 
422-     //CHECK-DAG: [[Y:%.+]] = arith.addi [[LOCALY]], [[c0]] : index 
423418    //CHECK-DAG: [[c128:%.+]] = arith.constant 128 : index 
424-     //CHECK-DAG: [[MODY:%.+]] = index.remu [[Y ]], [[c128]] 
419+     //CHECK-DAG: [[MODY:%.+]] = index.remu [[LY ]], [[c128]] 
425420    //CHECK-DAG: [[BASE:%.+]] = vector.step : vector<32xindex> 
426421    //CHECK-DAG: [[CAST:%.+]] = vector.broadcast [[MODY]] : index to vector<32xindex> 
427422    //CHECK: [[ADD:%.+]] = arith.addi [[BASE]], [[CAST]] : vector<32xindex> 
@@ -435,9 +430,8 @@ gpu.module @test_distribution {
435430    //CHECK-DAG: [[c8:%.+]] = arith.constant 8 : index 
436431    //CHECK-DAG: [[LOCALY:%.+]] = index.mul [[sgId]], [[c8]] 
437432    //CHECK-DAG: [[c0:%.+]] = arith.constant 0 : index 
438-     //CHECK-DAG: [[Y:%.+]] = arith.addi [[LOCALY]], [[c0]] : index 
439433    //CHECK-DAG: [[c128:%.+]] = arith.constant 128 : index 
440-     //CHECK-DAG: [[MODY:%.+]] = index.remu [[Y ]], [[c128]] 
434+     //CHECK-DAG: [[MODY:%.+]] = index.remu [[LOCALY ]], [[c128]] 
441435    //CHECK-DAG: [[BASE:%.+]] = vector.step : vector<8xindex> 
442436    //CHECK-DAG: [[CAST:%.+]] = vector.broadcast [[MODY]] : index to vector<8xindex> 
443437    //CHECK: [[ADD:%.+]] = arith.addi [[BASE]], [[CAST]] : vector<8xindex> 
0 commit comments