2009-01-16 04:18:42 +08:00
|
|
|
; Test to make sure that the 'private' is used correctly.
|
|
|
|
;
|
2011-11-01 18:41:28 +08:00
|
|
|
; RUN: llc < %s -march=xcore | FileCheck %s
|
2009-01-16 04:18:42 +08:00
|
|
|
|
|
|
|
define private void @foo() {
|
2011-11-01 18:41:28 +08:00
|
|
|
; CHECK: .Lfoo:
|
2009-01-16 04:18:42 +08:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
2010-01-06 01:55:26 +08:00
|
|
|
@baz = private global i32 4
|
2009-01-16 04:18:42 +08:00
|
|
|
|
|
|
|
define i32 @bar() {
|
2013-07-14 14:24:09 +08:00
|
|
|
; CHECK-LABEL: bar:
|
2011-11-01 18:41:28 +08:00
|
|
|
; CHECK: bl .Lfoo
|
|
|
|
; CHECK: ldw r0, dp[.Lbaz]
|
2009-01-16 04:18:42 +08:00
|
|
|
call void @foo()
|
2015-02-28 05:17:42 +08:00
|
|
|
%1 = load i32, i32* @baz, align 4
|
2009-01-16 04:18:42 +08:00
|
|
|
ret i32 %1
|
|
|
|
}
|
2011-11-01 18:41:28 +08:00
|
|
|
|
|
|
|
; CHECK: .Lbaz:
|