mirror of
https://github.com/RPCS3/llvm.git
synced 2026-07-19 23:23:38 -04:00
209d9a9a8d
Because of gp = sdata_start_address + 0x800, gp with signed twelve-bit offset could covert most of the small data section. Linker relaxation could transfer the multiple data accessing instructions to a gp base with signed twelve-bit offset instruction. Differential Revision: https://reviews.llvm.org/D57493 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@358150 91177308-0d34-0410-b5e6-96231b3b80d8
15 lines
504 B
LLVM
15 lines
504 B
LLVM
; RUN: llc -mtriple=riscv32 < %s | FileCheck -check-prefix=RV32 %s
|
|
; RUN: llc -mtriple=riscv64 < %s | FileCheck -check-prefix=RV64 %s
|
|
|
|
@v = dso_local global i32 0, align 4
|
|
@r = dso_local global i64 7, align 8
|
|
|
|
; SmallDataLimit set to 0, so we expect no data will put in sbss and sdata.
|
|
!llvm.module.flags = !{!0}
|
|
!0 = !{i32 1, !"SmallDataLimit", i32 0}
|
|
|
|
; RV32-NOT: .section .sbss
|
|
; RV32-NOT: .section .sdata
|
|
; RV64-NOT: .section .sbss
|
|
; RV64-NOT: .section .sdata
|