OSDN Git Service

[LLD][ELF][ARM] Don't apply --fix-cortex-a8 to relocatable links.
authorPeter Smith <peter.smith@linaro.org>
Tue, 21 Jan 2020 14:05:01 +0000 (14:05 +0000)
committerPeter Smith <peter.smith@linaro.org>
Wed, 22 Jan 2020 11:03:40 +0000 (11:03 +0000)
commite727f39ec0b15ee8aec52e83467299d79b2ea8f5
treed0f964957ace35869595206a393682b750c7ac05
parent9570f1e5a612348e92c2f149f5073ef06f9e5da5
[LLD][ELF][ARM] Don't apply --fix-cortex-a8 to relocatable links.

The --fix-cortex-a8 is sensitive to alignment and the precise destination
of branch instructions. These are not knowable at relocatable link time. We
follow GNU ld and the --fix-cortex-a53-843419 (D72968) by not patching the
code when there is a relocatable link.

Differential Revision: https://reviews.llvm.org/D73100
lld/ELF/Driver.cpp
lld/test/ELF/arm-fix-cortex-a8-recognize.s