1// REQUIRES: arm
2// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %s -o %t
3// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %S/Inputs/abs256.s -o %t256.o
4// RUN: ld.lld %t %t256.o -o %t2
5// RUN: llvm-objdump -d %t2 | FileCheck %s
6 .syntax unified
7 .globl _start
8_start:
9 .section .R_ARM_ABS32POS, "ax",%progbits
10 .word foo + 0x24
11
12// S = 0x100, A = 0x24
13// S + A = 0x124
14// CHECK: Disassembly of section .R_ARM_ABS32POS:
15// CHECK-EMPTY:
16// CHECK: 24 01 00 00
17 .section .R_ARM_ABS32NEG, "ax",%progbits
18 .word foo - 0x24
19// S = 0x100, A = -0x24
20// CHECK: Disassembly of section .R_ARM_ABS32NEG:
21// CHECK-EMPTY:
22// CHECK: dc 00 00 00
23