File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed
lib/Conversion/TosaToLinalg
test/Conversion/TosaToLinalg Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -1522,9 +1522,9 @@ class GenericResizeConverter : public OpRewritePattern<tosa::ResizeOp> {
1522
1522
xScaleD =
1523
1523
rewriter.create <arith::UIToFPOp>(loc, rewriter.getF32Type (), xScaleD);
1524
1524
yOffset =
1525
- rewriter.create <arith::UIToFPOp >(loc, rewriter.getF32Type (), yOffset);
1525
+ rewriter.create <arith::SIToFPOp >(loc, rewriter.getF32Type (), yOffset);
1526
1526
xOffset =
1527
- rewriter.create <arith::UIToFPOp >(loc, rewriter.getF32Type (), xOffset);
1527
+ rewriter.create <arith::SIToFPOp >(loc, rewriter.getF32Type (), xOffset);
1528
1528
1529
1529
y = rewriter.create <arith::MulFOp>(loc, y, yScaleD);
1530
1530
x = rewriter.create <arith::MulFOp>(loc, x, xScaleD);
Original file line number Diff line number Diff line change @@ -319,8 +319,8 @@ func.func @resize_nearest_fp(%input: tensor<1x50x48x1xf32>) -> () {
319
319
// CHECK: %[[SCALE_Y_D:.*]] = arith.uitofp %[[ISCALE_Y_D]]
320
320
// CHECK: %[[SCALE_X_N:.*]] = arith.uitofp %[[ISCALE_X_N]]
321
321
// CHECK: %[[SCALE_X_D:.*]] = arith.uitofp %[[ISCALE_X_D]]
322
- // CHECK: %[[OFFSET_Y:.*]] = arith.uitofp %[[IOFFSET_Y]]
323
- // CHECK: %[[OFFSET_X:.*]] = arith.uitofp %[[IOFFSET_X]]
322
+ // CHECK: %[[OFFSET_Y:.*]] = arith.sitofp %[[IOFFSET_Y]]
323
+ // CHECK: %[[OFFSET_X:.*]] = arith.sitofp %[[IOFFSET_X]]
324
324
325
325
// CHECK: %[[VAL_29:.*]] = arith.mulf %[[Y0]], %[[SCALE_Y_D]]
326
326
// CHECK: %[[VAL_30:.*]] = arith.mulf %[[X0]], %[[SCALE_X_D]]
@@ -397,8 +397,8 @@ func.func @resize_bilinear_fp(%input: tensor<1x23x23x1xf32>) -> () {
397
397
// CHECK: %[[SCALE_Y_D:.*]] = arith.uitofp %[[ISCALE_Y_D]]
398
398
// CHECK: %[[SCALE_X_N:.*]] = arith.uitofp %[[ISCALE_X_N]]
399
399
// CHECK: %[[SCALE_X_D:.*]] = arith.uitofp %[[ISCALE_X_D]]
400
- // CHECK: %[[OFFSET_Y:.*]] = arith.uitofp %[[IOFFSET_Y]]
401
- // CHECK: %[[OFFSET_X:.*]] = arith.uitofp %[[IOFFSET_X]]
400
+ // CHECK: %[[OFFSET_Y:.*]] = arith.sitofp %[[IOFFSET_Y]]
401
+ // CHECK: %[[OFFSET_X:.*]] = arith.sitofp %[[IOFFSET_X]]
402
402
403
403
// CHECK: %[[VAL_29:.*]] = arith.mulf %[[Y0]], %[[SCALE_Y_D]]
404
404
// CHECK: %[[VAL_30:.*]] = arith.mulf %[[X0]], %[[SCALE_X_D]]
You can’t perform that action at this time.
0 commit comments