1 ; modify_value will be inlined into main. With just the inliner pass, at most
2 ; some trivial DCE would happen, which in this case doesn't modify post-inlined
4 ; In contrast, with the full set of module inliner-related passes, at the end of
5 ; inlining (incl. function cleanups ran after inlining), main will be reduced to
8 ; RUN: opt -passes=inline -S < %s | FileCheck %s --check-prefix=INLINE --check-prefix=CHECK
9 ; RUN: opt -passes=inliner-wrapper -S < %s | FileCheck %s --check-prefix=INLINE --check-prefix=CHECK
10 ; RUN: opt -passes=scc-oz-module-inliner -S < %s | FileCheck %s --check-prefix=MODULE --check-prefix=CHECK
12 define void @modify_value({i32, float}* %v) {
13 %f = getelementptr { i32, float }, { i32, float }* %v, i64 0, i32 0
19 %my_val = alloca {i32, float}
20 call void @modify_value({i32, float}* %my_val)
21 %f = getelementptr { i32, float }, { i32, float }* %my_val, i64 0, i32 0
22 %ret = load i32, i32* %f
27 ; INLINE-NEXT: %my_val = alloca
28 ; MODULE-NEXT: ret i32 10