[llvm-bugs] [Bug 30267] New: Linker script orphan sections get an invalid address on AArch64
via llvm-bugs
llvm-bugs at lists.llvm.org
Sat Sep 3 03:00:55 PDT 2016
https://llvm.org/bugs/show_bug.cgi?id=30267
Bug ID: 30267
Summary: Linker script orphan sections get an invalid address
on AArch64
Product: lld
Version: unspecified
Hardware: PC
OS: FreeBSD
Status: NEW
Severity: normal
Priority: P
Component: ELF
Assignee: unassignedbugs at nondot.org
Reporter: andrew at fubar.geek.nz
CC: emaste at freebsd.org, llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 17211
--> https://llvm.org/bugs/attachment.cgi?id=17211&action=edit
objdump -x of the linked kernel
While trying to link the FreeBSD arm64 kernel I received around 45141 of the
following error:
relocation R_AARCH64_ADR_PREL_PG_HI21 out of range
After commenting out the check I linked the kernel and found the orphaned
sections were placed at the end of the file and started with a virtual address
of 0. This caused an overflow in the relocation.
It would seem binutils has a heuristic to put these sections after a section
with similar attributes:
https://sourceware.org/binutils/docs/ld/Orphan-Sections.html
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160903/8c27a394/attachment.html>
More information about the llvm-bugs
mailing list