xref: /llvm-project/mlir/test/Dialect/Vector/inlining.mlir (revision 8ba5c7a326bd4477aa3ce2dcfbc0ba991d7ff356)
1// RUN: mlir-opt %s -inline | FileCheck %s
2
3func.func @inner_func_inlinable(%v: f32) -> vector<4xf32> {
4  %1 = vector.broadcast %v : f32 to vector<4xf32>
5  return %1 : vector<4xf32>
6}
7
8// CHECK-LABEL: func.func @test_inline(
9//  CHECK-NOT:    func.call
10//  CHECK-NEXT:   vector.broadcast
11func.func @test_inline(%v: f32) -> vector<4xf32> {
12  %0 = call @inner_func_inlinable(%v) : (f32) -> vector<4xf32>
13  return %0 : vector<4xf32>
14}
15