Files
clang-p2996/mlir/test/Dialect/Bufferization/inlining.mlir
River Riddle 412b8850f6 [mlir][NFC] Update textual references of func to func.func in Bufferization/Complex/EmitC/CF/Func/GPU tests
The special case parsing of `func` operations is being removed.
2022-04-20 22:17:28 -07:00

17 lines
546 B
MLIR

// RUN: mlir-opt %s -inline | FileCheck %s
// CHECK-LABEL: func @test_inline
// CHECK-SAME: (%[[ARG:.*]]: memref<*xf32>)
// CHECK-NOT: call
// CHECK: %[[RES:.*]] = bufferization.clone %[[ARG]]
// CHECK: return %[[RES]]
func.func @test_inline(%buf : memref<*xf32>) -> memref<*xf32> {
%0 = call @inner_func(%buf) : (memref<*xf32>) -> memref<*xf32>
return %0 : memref<*xf32>
}
func.func @inner_func(%buf : memref<*xf32>) -> memref<*xf32> {
%clone = bufferization.clone %buf : memref<*xf32> to memref<*xf32>
return %clone : memref<*xf32>
}