llvm-mirror/test/MC/ARM/Windows/invalid-relocation.s
David Majnemer 47d3d1e5ef [MC, COFF] Support link /incremental conditionally
Today, we always take into account the possibility that object files
produced by MC may be consumed by an incremental linker.  This results
in us initialing fields which vary with time (TimeDateStamp) which harms
hermetic builds (e.g. verifying a self-host went well) and produces
sub-optimal code because we cannot assume anything about the relative
position of functions within a section (call sites can get redirected
through incremental linker thunks).

Let's provide an MCTargetOption which controls this behavior so that we
can disable this functionality if we know a-priori that the build will
not rely on /incremental.

llvm-svn: 256203
2015-12-21 22:09:27 +00:00

15 lines
356 B
ArmAsm

# RUN: not llvm-mc -triple thumbv7-windows -incremental-linker-compatible -filetype obj -o /dev/null 2>&1 %s \
# RUN: | FileCheck %s
.def invalid_relocation
.type 32
.scl 2
.endef
.global invalid_relocation
.thumb_func
invalid_relocation:
adr r0, invalid_relocation+1
# CHECK: LLVM ERROR: unsupported relocation type: fixup_t2_adr_pcrel_12