xref: /llvm-project/llvm/test/tools/llvm-reduce/remove-function-bodies-used-in-globals.ll (revision 195087d8152c3750a1aace67406140bd9e21244e)
1; RUN: llvm-reduce --test FileCheck --test-arg --check-prefix=CHECK-INTERESTINGNESS --abort-on-invalid-reduction --test-arg %s --test-arg --input-file %s -o %t
2; RUN: FileCheck --check-prefix=CHECK-FINAL %s < %t
3
4; We cannot change the @alias to undef, because it would result in invalid IR
5; (Aliasee should be either GlobalValue or ConstantExpr).
6
7; CHECK-INTERESTINGNESS: @alias =
8; CHECK-FINAL: @alias = alias void (i32), ptr @func
9
10@alias = alias void (i32), ptr @func
11
12; CHECK-FINAL: @func()
13
14define void @func(i32 %arg) {
15entry:
16  ret void
17}
18