binutils-gdb/gold/testsuite/aarch64_reloc_none.s
Igor Kudrin 5627d875bc Implement the R_AARCH64_NONE relocation.
According to "ELF for the ARM(r) 64-bit Architecture (AArch64)",
this relocation can be used "to prevent removal of sections that
might otherwise appear to be unused."

gold/
	* aarch64-reloc.def (NONE): New relocation.
	* aarch64.cc (Target_aarch64::Scan::local): Handle R_AARCH64_NONE.
	(Target_aarch64::Scan::global): Likewise.
	* testsuite/Makefile.am (aarch64_reloc_none): New test.
	* testsuite/Makefile.in: Regenerate.
	* testsuite/aarch64_reloc_none.s: New test source file.
	* testsuite/aarch64_reloc_none.sh: New test script.
2016-06-28 15:50:29 -07:00

17 lines
188 B
ArmAsm

.text
.global _start
.type _start, %function
_start:
nop
.reloc 0, R_AARCH64_NONE, foo
.section .foo,"ax"
.global foo
foo:
nop
.section .bar,"ax"
.global bar
bar:
nop