mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
7eae36b38b
fixes some cases where we were producing relocations with at symbol that should use a section instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115194 91177308-0d34-0410-b5e6-96231b3b80d8
58 lines
1.6 KiB
ArmAsm
58 lines
1.6 KiB
ArmAsm
// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | elf-dump --dump-section-data | FileCheck %s
|
|
|
|
// Test that we produce a R_X86_64_32S or R_X86_64_32.
|
|
|
|
bar:
|
|
movl $bar, %edx // R_X86_64_32
|
|
movq $bar, %rdx // R_X86_64_32S
|
|
movq $bar, bar(%rip) // R_X86_64_32S
|
|
movl bar, %edx // R_X86_64_32S
|
|
movq bar, %rdx // R_X86_64_32S
|
|
.long bar // R_X86_64_32
|
|
|
|
// CHECK: # Section 1
|
|
// CHECK: (('sh_name', 1) # '.text'
|
|
|
|
// CHECK: # Symbol 2
|
|
// CHECK: (('st_name', 0) # ''
|
|
// CHECK: ('st_bind', 0)
|
|
// CHECK ('st_type', 3)
|
|
// CHECK: ('st_other', 0)
|
|
// CHECK: ('st_shndx', 1)
|
|
|
|
// CHECK: # Relocation 0
|
|
// CHECK-NEXT: (('r_offset', 1)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 10)
|
|
// CHECK-NEXT: ('r_addend',
|
|
|
|
// CHECK: # Relocation 1
|
|
// CHECK-NEXT: (('r_offset', 8)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 11)
|
|
// CHECK-NEXT: ('r_addend',
|
|
|
|
// CHECK: # Relocation 2
|
|
// CHECK-NEXT: (('r_offset', 19)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 11)
|
|
// CHECK-NEXT: ('r_addend',
|
|
|
|
// CHECK: # Relocation 3
|
|
// CHECK-NEXT: (('r_offset', 26)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 11)
|
|
// CHECK-NEXT: ('r_addend',
|
|
|
|
// CHECK: # Relocation 4
|
|
// CHECK-NEXT: (('r_offset', 34)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 11)
|
|
// CHECK-NEXT: ('r_addend',
|
|
|
|
// CHECK: # Relocation 5
|
|
// CHECK-NEXT: (('r_offset', 38)
|
|
// CHECK-NEXT: ('r_sym', 2)
|
|
// CHECK-NEXT: ('r_type', 10)
|
|
// CHECK-NEXT: ('r_addend',
|