annotate lld/test/ELF/aarch64-abs32.s @ 150:1d019706d866

LLVM10
author anatofuz
date Thu, 13 Feb 2020 15:10:13 +0900
parents
children 0572611fdcc8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // REQUIRES: aarch64
anatofuz
parents:
diff changeset
2 // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %s -o %t.o
anatofuz
parents:
diff changeset
3 // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %S/Inputs/abs255.s -o %t255.o
anatofuz
parents:
diff changeset
4 // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %S/Inputs/abs256.s -o %t256.o
anatofuz
parents:
diff changeset
5 // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %S/Inputs/abs257.s -o %t257.o
anatofuz
parents:
diff changeset
6
anatofuz
parents:
diff changeset
7 .globl _start
anatofuz
parents:
diff changeset
8 _start:
anatofuz
parents:
diff changeset
9 .data
anatofuz
parents:
diff changeset
10 .word foo + 0xfffffeff
anatofuz
parents:
diff changeset
11 .word foo - 0x80000100
anatofuz
parents:
diff changeset
12
anatofuz
parents:
diff changeset
13 // RUN: ld.lld %t.o %t256.o -o %t2
anatofuz
parents:
diff changeset
14 // RUN: llvm-objdump -s -section=.data %t2 | FileCheck %s
anatofuz
parents:
diff changeset
15
anatofuz
parents:
diff changeset
16 // CHECK: Contents of section .data:
anatofuz
parents:
diff changeset
17 // 220158: S = 0x100, A = 0xfffffeff
anatofuz
parents:
diff changeset
18 // S + A = 0xffffffff
anatofuz
parents:
diff changeset
19 // 22015c: S = 0x100, A = -0x80000100
anatofuz
parents:
diff changeset
20 // S + A = 0x80000000
anatofuz
parents:
diff changeset
21 // CHECK-NEXT: 220158 ffffffff 00000080
anatofuz
parents:
diff changeset
22
anatofuz
parents:
diff changeset
23 // RUN: not ld.lld %t.o %t255.o -o /dev/null 2>&1 | FileCheck %s --check-prefix=OVERFLOW1
anatofuz
parents:
diff changeset
24 // OVERFLOW1: relocation R_AARCH64_ABS32 out of range: -2147483649 is not in [-2147483648, 4294967295]; references foo
anatofuz
parents:
diff changeset
25
anatofuz
parents:
diff changeset
26 // RUN: not ld.lld %t.o %t257.o -o /dev/null 2>&1 | FileCheck %s --check-prefix=OVERFLOW2
anatofuz
parents:
diff changeset
27 // OVERFLOW2: relocation R_AARCH64_ABS32 out of range: 4294967296 is not in [-2147483648, 4294967295]; references foo