HomePhabricator

[ELF][ARM] Do not create .ARM.exidx sections for out of range inputs

Authored by psmith on May 2 2020, 3:16 AM.

Description

[ELF][ARM] Do not create .ARM.exidx sections for out of range inputs

A linker will create .ARM.exidx sections for InputSections that don't
have them. This can cause a relocation out of range error If the
InputSection happens to be extremely far away from the other sections.
This is often the case for the vector table on older ARM CPUs as the only
two places that the table can be placed is 0 or 0xffff0000. We fix this
by removing InputSections that need a linker generated .ARM.exidx
section if that would cause an error.

Differential Revision: https://reviews.llvm.org/D79289

Details