1 ; Test loads of symbolic addresses in PIC code.
3 ; RUN: llc < %s -mtriple=s390x-linux-gnu -relocation-model=pic | FileCheck %s
5 @ev = external global i32
7 @pv = protected global i32 0
8 @hv = hidden global i32 0
14 define protected void @pf() {
17 define hidden void @hf() {
21 ; Test loads of external variables, which must go via the GOT.
24 ; CHECK: lgrl %r2, ev@GOT
29 ; Check loads of locally-defined normal-visibility variables, which might
30 ; be overridden. The load must go via the GOT.
33 ; CHECK: lgrl %r2, dv@GOT
38 ; Check loads of protected variables, which in the small code model
39 ; must be in range of LARL.
47 ; ...likewise hidden variables.
55 ; Like f1, but for functions.
58 ; CHECK: lgrl %r2, ef@GOT
63 ; Like f2, but for functions.
66 ; CHECK: lgrl %r2, df@GOT
71 ; Like f3, but for functions.
79 ; Like f4, but for functions.