diff --git a/test/mlir/onnx/onnx_lowering_with_dealloc.mlir b/test/mlir/onnx/onnx_lowering_with_dealloc.mlir index 4216ffa..385dc3c 100644 --- a/test/mlir/onnx/onnx_lowering_with_dealloc.mlir +++ b/test/mlir/onnx/onnx_lowering_with_dealloc.mlir @@ -315,14 +315,8 @@ func @test_tanh_tanh(%arg0 : tensor) -> tensor<*xf32> { // CHECK: [[DIM_2:%.+]] = dim %arg0, 0 : memref // CHECK: krnl.iterate([[OPT_LOOPS]]#0, [[OPT_LOOPS]]#1) with ([[DEF_LOOPS]]#0 -> %arg1 = 0 to [[DIM_2]], [[DEF_LOOPS]]#1 -> %arg2 = 0 to 10) { // CHECK: [[LOAD:%.+]] = load %arg0[%arg1, %arg2] : memref - // CHECK: [[ZERO:%.+]] = constant {{0.+}} : f32 - // CHECK: [[NLOAD:%.+]] = subf [[ZERO]], [[LOAD]] : f32 - // CHECK: [[EXP:%.+]] = exp [[LOAD]] : f32 - // CHECK: [[NEXP:%.+]] = exp [[NLOAD]] : f32 - // CHECK: [[DIVIDEND:%.+]] = subf [[EXP]], [[NEXP]] : f32 - // CHECK: [[DIVISOR:%.+]] = addf [[EXP]], [[NEXP]] : f32 - // CHECK: [[TANH_RES:%.+]] = divf [[DIVIDEND]], [[DIVISOR]] : f32 - // CHECK: store [[TANH_RES]], [[RES]][%arg1, %arg2] : memref + // CHECK: [[TANH:%.+]] = tanh [[LOAD]] : f32 + // CHECK: store [[TANH]], [[RES]][%arg1, %arg2] : memref /// Second Tanh // CHECK: [[DIM_0:%.+]] = dim [[RES]], 0 : memref @@ -334,13 +328,7 @@ func @test_tanh_tanh(%arg0 : tensor) -> tensor<*xf32> { // CHECK: [[DIM_2:%.+]] = dim [[RES]], 0 : memref // CHECK: krnl.iterate([[OPT_LOOPS]]#0, [[OPT_LOOPS]]#1) with ([[DEF_LOOPS]]#0 -> %arg1 = 0 to [[DIM_2]], [[DEF_LOOPS]]#1 -> %arg2 = 0 to 10) { // CHECK: [[LOAD:%.+]] = load [[RES]][%arg1, %arg2] : memref - // CHECK: [[ZERO:%.+]] = constant {{0.+}} : f32 - // CHECK: [[NLOAD:%.+]] = subf [[ZERO]], [[LOAD]] : f32 - // CHECK: [[EXP:%.+]] = exp [[LOAD]] : f32 - // CHECK: [[NEXP:%.+]] = exp [[NLOAD]] : f32 - // CHECK: [[DIVIDEND:%.+]] = subf [[EXP]], [[NEXP]] : f32 - // CHECK: [[DIVISOR:%.+]] = addf [[EXP]], [[NEXP]] : f32 - // CHECK: [[TANH_RES:%.+]] = divf [[DIVIDEND]], [[DIVISOR]] : f32 + // CHECK: [[TANH_RES:%.+]] = tanh [[LOAD]] : f32 // CHECK: store [[TANH_RES]], [[RET_RES]][%arg1, %arg2] : memref /// Dealloc of first result.