Skip to content

Commit 23ed15e

Browse files
Tai78641zahiraam
authored andcommitted
[TOSA] Change EightK MaxScale to 256 (llvm#66536)
This patch changes the MaxScale value for level EightK to 256. Also updated affected level check tests Change-Id: Id9cffd5eb9053bb688196cd5b3b55b3ddd2a359c Signed-off-by: Tai Ly <[email protected]>
1 parent dd582cb commit 23ed15e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

mlir/lib/Dialect/Tosa/Transforms/TosaValidation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ struct tosa_level_t {
8686
}
8787
};
8888

89-
static constexpr tosa_level_t TOSA_LEVEL_EIGHTK = {6, 8192, 8192, 64};
89+
static constexpr tosa_level_t TOSA_LEVEL_EIGHTK = {6, 8192, 8192, 256};
9090
static constexpr tosa_level_t TOSA_LEVEL_NONE = {0, 0, 0, 0};
9191

9292
//===----------------------------------------------------------------------===//

mlir/test/Dialect/Tosa/level_check.mlir

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -639,7 +639,7 @@ func.func @test_transpose_conv2d_stride_x(%arg0: tensor<1x32x32x8xf32>, %arg1: t
639639

640640
func.func @test_resize_scale_y(%arg0: tensor<1x32x32x8xf32>) -> tensor<1x64x64x8xf32> {
641641
// expected-error@+1 {{'tosa.resize' op failed level check: scale_y_n/scale_y_d <= MAX_SCALE}}
642-
%1 = "tosa.resize"(%arg0) { scale = array<i64: 65, 1, 4, 2>, offset = array<i64: -1, -1>, border = array<i64: 1, 1>, mode = "BILINEAR"} :
642+
%1 = "tosa.resize"(%arg0) { scale = array<i64: 257, 1, 4, 2>, offset = array<i64: -1, -1>, border = array<i64: 1, 1>, mode = "BILINEAR"} :
643643
(tensor<1x32x32x8xf32>) -> tensor<1x64x64x8xf32>
644644
return %1 : tensor<1x64x64x8xf32>
645645
}
@@ -648,7 +648,7 @@ func.func @test_resize_scale_y(%arg0: tensor<1x32x32x8xf32>) -> tensor<1x64x64x8
648648

649649
func.func @test_resize_scale_x(%arg0: tensor<1x32x32x8xf32>) -> tensor<1x64x64x8xf32> {
650650
// expected-error@+1 {{'tosa.resize' op failed level check: scale_x_n/scale_x_d <= MAX_SCALE}}
651-
%1 = "tosa.resize"(%arg0) { scale = array<i64: 4, 2, 65, 1>, offset = array<i64: -1, -1>, border = array<i64: 1, 1>, mode = "BILINEAR"} :
651+
%1 = "tosa.resize"(%arg0) { scale = array<i64: 4, 2, 257, 1>, offset = array<i64: -1, -1>, border = array<i64: 1, 1>, mode = "BILINEAR"} :
652652
(tensor<1x32x32x8xf32>) -> tensor<1x64x64x8xf32>
653653
return %1 : tensor<1x64x64x8xf32>
654654
}

0 commit comments

Comments
 (0)