[PowerPC] Recommit r314244 with refactoring and off by default
[llvm-core.git] / test / CodeGen / PowerPC / private.ll
blobb2412080fedf949e87448db8681fa7f5f03b999d
1 ; Test to make sure that the 'private' is used correctly.
3 ; RUN: llc -verify-machineinstrs < %s -mtriple=powerpc-unknown-linux-gnu | \
4 ; RUN: FileCheck --check-prefix=LINUX %s
6 ; RUN: llc -verify-machineinstrs < %s -mtriple=powerpc-apple-darwin | \
7 ; RUN: FileCheck --check-prefix=OSX %s
9 ; LINUX: .Lfoo:
10 ; OSX: l_foo:
11 define private void @foo() nounwind {
12         ret void
15 define i32 @bar() nounwind {
16 ; LINUX: bl{{.*}}.Lfoo
17 ; OSX: bl{{.*}}l_foo
18         call void @foo()
20 ; LINUX: lis{{.*}}.Lbaz
21 ; OSX:  lis{{.*}}l_baz
22         %1 = load i32, i32* @baz, align 4
23         ret i32 %1
26 ; LINUX: .Lbaz:
27 ; OSX: l_baz:
28 @baz = private global i32 4