aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/PowerPC/private.ll
blob: 633fa651037f78c00c750c04065ecceb1aa3466f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
; Test to make sure that the 'private' is used correctly.
;
; RUN: llc < %s -mtriple=powerpc-unknown-linux-gnu | \
; RUN: FileCheck --check-prefix=LINUX %s
;
; RUN: llc < %s -mtriple=powerpc-apple-darwin | \
; RUN: FileCheck --check-prefix=OSX %s

; LINUX: .Lfoo:
; OSX: l_foo:
define private void @foo() nounwind {
        ret void
}

define i32 @bar() nounwind {
; LINUX: bl{{.*}}.Lfoo
; OSX: bl{{.*}}l_foo
        call void @foo()

; LINUX: lis{{.*}}.Lbaz
; OSX:  lis{{.*}}l_baz
	%1 = load i32* @baz, align 4
        ret i32 %1
}

; LINUX: .Lbaz:
; OSX: l_baz:
@baz = private global i32 4