xref: /llvm-project/llvm/test/Linker/pr21374.ll (revision 11c7a753886ce46de52559929a2e05f036e0b16b)
1; RUN: llvm-link -S -o - %p/pr21374.ll %p/Inputs/pr21374.ll | FileCheck %s
2; RUN: llvm-link -S -o - %p/Inputs/pr21374.ll %p/pr21374.ll | FileCheck %s
3
4; RUN: llvm-as -o %t1.bc %p/pr21374.ll
5; RUN: llvm-as -o %t2.bc %p/Inputs/pr21374.ll
6
7; RUN: llvm-link -S -o - %t1.bc %t2.bc | FileCheck %s
8; RUN: llvm-link -S -o - %t2.bc %t1.bc | FileCheck %s
9
10; Test that we get the same result with or without lazy loading.
11
12; CHECK: %foo = type { ptr }
13; CHECK-DAG: getelementptr %foo, ptr null, i64 1
14; CHECK-DAG: define void @g(%foo %x)
15
16%foo = type { ptr }
17define void @f() {
18  getelementptr %foo, ptr null, i64 1
19  ret void
20}
21