@@ -1161,11 +1161,11 @@ func.func @rescale_i8_unsigned_output(%arg0 : tensor<2xi8>) -> () {
1161
1161
// CHECK: [[GENERIC:%.+]] = linalg.generic {indexing_maps = [#[[$MAP0]], #[[$MAP0]]], iterator_types = ["parallel"]} ins(%[[ARG0]] : tensor<2xi8>) outs([[INIT]] : tensor<2xi8>)
1162
1162
// CHECK: ^bb0([[IN:%.+]]: i8, [[UNUSED:%.+]]: i8):
1163
1163
// CHECK: [[C17:%.+]] = arith.constant 17
1164
- // CHECK: [[C22 :%.+]] = arith.constant 22
1164
+ // CHECK: [[C234 :%.+]] = arith.constant 234
1165
1165
// CHECK-DAG: [[IN32:%.+]] = arith.extsi [[IN]]
1166
1166
// CHECK-DAG: [[IN_ZEROED:%.+]] = arith.subi [[IN32]], [[C17]]
1167
1167
// CHECK-DAG: [[SCALED:%.+]] = tosa.apply_scale [[IN_ZEROED]], [[C0]], [[C1]] {rounding_mode = "SINGLE_ROUND"}
1168
- // CHECK-DAG: [[SCALED_ZEROED:%.+]] = arith.addi [[SCALED]], [[C22 ]]
1168
+ // CHECK-DAG: [[SCALED_ZEROED:%.+]] = arith.addi [[SCALED]], [[C234 ]]
1169
1169
// CHECK-DAG: [[CMIN:%.+]] = arith.constant 0
1170
1170
// CHECK-DAG: [[CMAX:%.+]] = arith.constant 255
1171
1171
// CHECK-DAG: [[LOWER:%.+]] = arith.maxsi [[CMIN]], [[SCALED_ZEROED]]
@@ -1175,7 +1175,7 @@ func.func @rescale_i8_unsigned_output(%arg0 : tensor<2xi8>) -> () {
1175
1175
%multiplier = " tosa.const" () {values = dense <19689 > : tensor <1 xi16 > } : () -> tensor <1 xi16 >
1176
1176
%shift = " tosa.const" () {values = dense <15 > : tensor <1 xi8 > } : () -> tensor <1 xi8 >
1177
1177
%input_zp = " tosa.const" () {values = dense <17 > : tensor <1 xi8 >} : () -> tensor <1 xi8 >
1178
- %output_zp = " tosa.const" () {values = dense <22 > : tensor <1 xi8 >} : () -> tensor <1 xi8 >
1178
+ %output_zp = " tosa.const" () {values = dense <- 22 > : tensor <1 xi8 >} : () -> tensor <1 xi8 >
1179
1179
%1 = tosa.rescale %arg0 , %multiplier , %shift , %input_zp , %output_zp {scale32 = false , rounding_mode = " SINGLE_ROUND" , per_channel = false , input_unsigned = false , output_unsigned = true } : (tensor <2 xi8 >, tensor <1 xi16 >, tensor <1 xi8 >, tensor <1 xi8 >, tensor <1 xi8 >) -> tensor <2 xi8 >
1180
1180
1181
1181
// CHECK: return
0 commit comments