1 ; All of the functions in this module must end up
2 ; in the same partition.
4 ; RUN: llvm-split -j=2 -preserve-locals -o %t %s
5 ; RUN: llvm-dis -o - %t0 | FileCheck --check-prefix=CHECK1 %s
6 ; RUN: llvm-dis -o - %t1 | FileCheck --check-prefix=CHECK0 %s
8 ; CHECK0: declare dso_local i32 @funInternal0
9 ; CHECK0: declare dso_local i32 @funInternal1
10 ; CHECK0: declare dso_local i32 @funInternal2
11 ; CHECK0: declare i32 @funExternal
13 ; All functions are in the same file.
14 ; Local functions are still local.
15 ; CHECK1: define internal i32 @funInternal0
16 ; CHECK1: define internal i32 @funInternal1
17 ; CHECK1: define internal i32 @funInternal2
18 ; CHECK1: define i32 @funExternal
19 ; CHECK1: define i32 @funExternal2
21 define internal i32 @funInternal0() {
26 define internal i32 @funInternal1() {
28 %x = call i32 @funInternal0()
32 define internal i32 @funInternal2() {
34 %x = call i32 @funInternal1()
38 define i32 @funExternal() {
40 %x = call i32 @funInternal2()
44 define i32 @funExternal2() {
46 %x = call i32 @funInternal0()