commit | ff54d4faecc1687516d1ae1e3d81a9c9d238123d | [log] [tgz] |
---|---|---|
author | Peter Collingbourne <peter@pcc.me.uk> | Mon Sep 30 20:23:00 2019 +0000 |
committer | Peter Collingbourne <peter@pcc.me.uk> | Mon Sep 30 20:23:00 2019 +0000 |
tree | f1b14b4f913339978a8e3a6c1d0146f63abfa25e | |
parent | 49042c57ce1b49a303adc0ed2ccc1b1763cfe0bc [diff] |
ELF: Don't merge SHF_LINK_ORDER sections for different output sections in relocatable links. Merging SHF_LINK_ORDER sections can affect semantics if the sh_link fields point to different sections. Specifically, for SHF_LINK_ORDER sections, the sh_link field acts as a reverse dependency from the linked section, causing the SHF_LINK_ORDER section to be included if the linked section is included. Merging sections with different sh_link fields will cause the entire contents of the SHF_LINK_ORDER section to be associated with a single (arbitrarily chosen) output section, whereas the correct semantics are for the individual pieces of the SHF_LINK_ORDER section to be associated with their linked output sections. As a result we can end up incorrectly dropping SHF_LINK_ORDER section contents or including the wrong section contents, depending on which linked sections were chosen. Differential Revision: https://reviews.llvm.org/D68094 git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@373255 91177308-0d34-0410-b5e6-96231b3b80d8
This directory and its subdirectories contain source code for the LLVM Linker, a modular cross platform linker which is built as part of the LLVM compiler infrastructure project.
lld is open source software. You may freely distribute it under the terms of the license agreement found in LICENSE.txt.
In order to make sure various developers can evaluate patches over the same tests, we create a collection of self contained programs.
It is hosted at https://s3-us-west-2.amazonaws.com/linker-tests/lld-speed-test.tar.xz
The current sha256 is 10eec685463d5a8bbf08d77f4ca96282161d396c65bd97dc99dbde644a31610f.