xref: /llvm-project/llvm/test/ExecutionEngine/OrcLazy/basic-whole-module-partitions.ll (revision 2d56d8c4e8751c7e2cab927cdeb4e519af3f3585)
1; RUN: lli -jit-kind=orc-lazy -orc-lazy-debug=funcs-to-stdout \
2; RUN:   %s | FileCheck --check-prefix=CHECK-PER-FUNCTION %s
3; RUN: lli -jit-kind=orc-lazy -per-module-lazy -orc-lazy-debug=funcs-to-stdout \
4; RUN:   %s | FileCheck --check-prefix=CHECK-WHOLE-MODULE %s
5;
6; CHECK-PER-FUNCTION-NOT: foo
7; CHECK-WHOLE-MODULE: foo
8;
9; Checks that the whole module is emitted when -per-module-lazy is enabled,
10; even though foo is not called.
11; Also checks that the foo function is not emitted when -per-module-lazy is off.
12
13define void @foo() {
14entry:
15  ret void
16}
17
18define i32 @main(i32 %argc, ptr nocapture readnone %argv) {
19entry:
20  ret i32 0
21}
22