mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-26 04:32:44 +01:00
e538054e6d
Currently, if the assembler encounters an error after parsing (such as an out-of-range fixup), it reports this as a fatal error, and so stops after the first error. However, for most of these there is an obvious way to recover after emitting the error, such as emitting the fixup with a value of zero. This means that we can report on all of the errors in a file, not just the first one. MCContext::reportError records the fact that an error was encountered, so we won't actually emit an object file with the incorrect contents. Differential Revision: http://reviews.llvm.org/D14717 llvm-svn: 253328
36 lines
690 B
ArmAsm
36 lines
690 B
ArmAsm
@ RUN: not llvm-mc -triple thumbv6m-none-macho -filetype=obj -o /dev/null %s 2>&1 | FileCheck %s
|
|
@ RUN: not llvm-mc -triple thumbv6m-none-eabi -filetype=obj -o /dev/null %s 2>&1 | FileCheck %s
|
|
|
|
Lhere:
|
|
@ CHECK: out of range pc-relative fixup value
|
|
ldr r0, Lhere
|
|
|
|
@ CHECK: out of range pc-relative fixup value
|
|
b Lfar2
|
|
|
|
@ CHECK: out of range pc-relative fixup value
|
|
bne Lfar1
|
|
|
|
@ CHECK: out of range pc-relative fixup value
|
|
ldr r0, Lfar2
|
|
|
|
@ CHECK: misaligned pc-relative fixup value
|
|
adr r0, Lmisaligned
|
|
|
|
@ CHECK: misaligned pc-relative fixup value
|
|
ldr r0, Lmisaligned
|
|
|
|
.balign 4
|
|
.short 0
|
|
Lmisaligned:
|
|
.word 42
|
|
|
|
.space 256
|
|
Lfar1:
|
|
.word 42
|
|
|
|
.space 2050
|
|
Lfar2:
|
|
.word 42
|
|
|