Skip to content

Commit c93b45a

Browse files
authored
[mlir][ArmSME] Reword in-memory tile warning (NFC) (llvm#92415)
It did not make sense that this said "all tile operations will go through memory". Only the operations where the warning is emitted will go through memory. The message has been updated to reflect that.
1 parent 698cf01 commit c93b45a

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

mlir/lib/Conversion/ArmSMEToLLVM/ArmSMEToLLVM.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,8 +248,8 @@ struct ConvertArmSMESpillsAndFillsToLLVM : public ConvertToLLVMPattern {
248248
return failure();
249249

250250
tileOp->emitWarning(
251-
"failed to allocate SME virtual tile to operation, all tile "
252-
"operations will go through memory, expect degraded performance");
251+
"failed to allocate SME virtual tile to operation, tile value will go "
252+
"through memory, expect degraded performance");
253253

254254
// Step 1. Create an alloca for the tile at the top of the function (if one
255255
// does not already exist).

mlir/test/Conversion/ArmSMEToLLVM/tile-spills-and-fills.mlir

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
func.func @use_too_many_tiles() {
5555
%0 = arm_sme.zero : vector<[4]x[4]xi32>
5656
%1 = arm_sme.zero : vector<[4]x[4]xi32>
57-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
57+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
5858
%2 = arm_sme.zero : vector<[8]x[8]xi16>
5959
"test.some_use"(%0) : (vector<[4]x[4]xi32>) -> ()
6060
"test.some_use"(%1) : (vector<[4]x[4]xi32>) -> ()
@@ -138,7 +138,7 @@ func.func @very_excessive_spills(%useAllTiles : vector<[16]x[16]xi8>, %memref: m
138138
%c0 = arith.constant 0 : index
139139
%tile = arm_sme.get_tile : vector<[4]x[4]xf32>
140140
%mask = vector.constant_mask [4] : vector<[4]xi1>
141-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
141+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
142142
%loadSlice = arm_sme.load_tile_slice %memref[%c0, %c0], %mask, %tile, %c0 : memref<?x?xf32>, vector<[4]xi1>, vector<[4]x[4]xf32>
143143
"test.some_use"(%useAllTiles) : (vector<[16]x[16]xi8>) -> ()
144144
"test.some_use"(%loadSlice) : (vector<[4]x[4]xf32>) -> ()

mlir/test/Integration/Dialect/Linalg/CPU/ArmSME/use-too-many-tiles.mlir

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,29 +13,29 @@
1313
/// performance (hence the warning).
1414
func.func @use_too_many_tiles(%a: memref<?x?xi16>, %b: memref<?x?xi16>, %c: memref<?x?xi16>) {
1515
%c0 = arith.constant 0 : index
16-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
16+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
1717
%tile_a = arith.constant dense<0> : vector<[8]x[8]xi16>
18-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
18+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
1919
%tile_b = arith.constant dense<1> : vector<[8]x[8]xi16>
20-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
20+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
2121
%tile_c = arm_sme.tile_load %a[%c0, %c0] : memref<?x?xi16>, vector<[8]x[8]xi16>
2222
%tile_d = arm_sme.tile_load %b[%c0, %c0] : memref<?x?xi16>, vector<[8]x[8]xi16>
2323
%tile_e = arm_sme.tile_load %c[%c0, %c0] : memref<?x?xi16>, vector<[8]x[8]xi16>
2424

2525
// CHECK-LABEL: tile_a:
2626
// CHECK-COUNT-8: ( 0, 0, 0, 0, 0, 0, 0, 0
2727
vector.print str "tile_a:\n"
28-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
28+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
2929
vector.print %tile_a : vector<[8]x[8]xi16>
3030
// CHECK-LABEL: tile_b:
3131
// CHECK-COUNT-8: ( 1, 1, 1, 1, 1, 1, 1, 1
3232
vector.print str "tile_b:\n"
33-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
33+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
3434
vector.print %tile_b : vector<[8]x[8]xi16>
3535
// CHECK-LABEL: tile_c:
3636
// CHECK-COUNT-8: ( 2, 2, 2, 2, 2, 2, 2, 2
3737
vector.print str "tile_c:\n"
38-
// expected-warning @below {{failed to allocate SME virtual tile to operation, all tile operations will go through memory, expect degraded performance}}
38+
// expected-warning @below {{failed to allocate SME virtual tile to operation, tile value will go through memory, expect degraded performance}}
3939
vector.print %tile_c : vector<[8]x[8]xi16>
4040
// CHECK-LABEL: tile_d:
4141
// CHECK-COUNT-8: ( 3, 3, 3, 3, 3, 3, 3, 3

0 commit comments

Comments
 (0)