2009-01-15 21:18:42 +01:00
|
|
|
; Test to make sure that the 'private' is used correctly.
|
|
|
|
;
|
2011-12-02 23:28:09 +01:00
|
|
|
; RUN: llc -march=mips < %s | FileCheck %s
|
2009-01-15 21:18:42 +01:00
|
|
|
|
|
|
|
define private void @foo() {
|
2011-12-02 23:28:09 +01:00
|
|
|
; CHECK: foo:
|
|
|
|
ret void
|
2009-01-15 21:18:42 +01:00
|
|
|
}
|
|
|
|
|
2010-01-05 18:55:26 +01:00
|
|
|
@baz = private global i32 4
|
2009-01-15 21:18:42 +01:00
|
|
|
|
|
|
|
define i32 @bar() {
|
2011-12-02 23:28:09 +01:00
|
|
|
; CHECK: bar:
|
|
|
|
; CHECK: call16($foo)
|
|
|
|
; CHECK: lw $[[R0:[0-9]+]], %got($baz)($
|
|
|
|
; CHECK: lw ${{[0-9]+}}, %lo($baz)($[[R0]])
|
|
|
|
call void @foo()
|
|
|
|
%1 = load i32* @baz, align 4
|
|
|
|
ret i32 %1
|
2009-01-15 21:18:42 +01:00
|
|
|
}
|