mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-24 12:19:53 +00:00
22f5417147
This reduces code duplication and now AArch64 also handles PIE. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@270844 91177308-0d34-0410-b5e6-96231b3b80d8
15 lines
294 B
LLVM
15 lines
294 B
LLVM
; RUN: llc -mtriple aarch64-pc-linux -relocation-model=pic < %s | FileCheck %s
|
|
|
|
@g1 = global i32 42
|
|
|
|
define i32* @get_g1() {
|
|
; CHECK: get_g1:
|
|
; CHECK: adrp x0, g1
|
|
; CHECK-NEXT: add x0, x0, :lo12:g1
|
|
ret i32* @g1
|
|
}
|
|
|
|
!llvm.module.flags = !{!0}
|
|
|
|
!0 = !{i32 1, !"PIE Level", i32 2}
|