Merging r312706:
------------------------------------------------------------------------
r312706 | anng | 2017-09-07 01:43:56 -0700 (Thu, 07 Sep 2017) | 14 lines

[LLD] Fix padding of .eh_frame when in executable segment

The default padding for an executable segment is the target trap
instruction which for x86_64 is 0xCC. However, the .eh_frame section
requires the padding to be zero. The code that writes the .eh_frame
section assumes that its segment is zero initialized and does not
explicitly write the zero padding. This does not work when the .eh_frame
section is in the executable segment (for example when using
-no-rosegment).

This patch changes the .eh_frame writing code to explicitly write the
zero padding.

Differential Revision: https://reviews.llvm.org/D37462
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/lld/branches/release_50@314861 91177308-0d34-0410-b5e6-96231b3b80d8
2 files changed
tree: 103332e855e69639d8a14780e4e1d02fc4f53738
  1. cmake/
  2. COFF/
  3. docs/
  4. ELF/
  5. include/
  6. lib/
  7. test/
  8. tools/
  9. unittests/
  10. .arcconfig
  11. .clang-format
  12. .gitignore
  13. CMakeLists.txt
  14. CODE_OWNERS.TXT
  15. LICENSE.TXT
  16. README.md
README.md

LLVM Linker (lld)

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.