llvm-project/lld
Brian Gesiak b9f7f4b87c [Darwin] Use errorHandler from liblldCommon
Summary:
Error handling in liblldCore and the Darwin toolchain prints to an
output stream. A TODO in the project explained that a diagnostics
interface resembling Clang's should be added.

For now, the simple diagnostics interface defined in liblldCommon seems
like an improvement. It prints colors when they're available, uses locks
for thread-safety, and abstracts away the `"error: "` and newline
literal strings that litter the Darwin toolchain code.

To use the liblldCommon error handler, a link dependency is added to
the liblldDriver library.

Test Plan:
1. check-lld
2. Invoke `ld64.lld -r` in a terminal that supports color output.
   Confirm that "ld64.lld: error: -arch not specified and could not be inferred"
   is output, and that the "error:" is colored red!

Reviewers: ruiu, smeenai

Reviewed By: ruiu

Subscribers: mgorny, llvm-commits

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

llvm-svn: 334466
2018-06-12 02:34:04 +00:00
..
COFF [COFF] report file containing unsupported relocation 2018-06-07 00:50:03 +00:00
Common Code cleanup in preparation for adding LTO for wasm. NFC. 2018-05-22 20:20:25 +00:00
ELF [PPC64] Support R_PPC64_DTPREL relocations. 2018-06-12 01:47:02 +00:00
MinGW [MinGW] Handle the GNU ld option -Map for outputting a linker map 2018-05-15 21:12:29 +00:00
cmake/modules [CMake] Properly conditionalize installation of lld libraries 2018-03-09 13:09:36 +00:00
docs Implement --{push,pop}-state. 2018-05-31 13:00:25 +00:00
include/lld [Darwin] Use errorHandler from liblldCommon 2018-06-12 02:34:04 +00:00
lib [Darwin] Use errorHandler from liblldCommon 2018-06-12 02:34:04 +00:00
test [PPC64] Support R_PPC64_DTPREL relocations. 2018-06-12 01:47:02 +00:00
tools/lld [Darwin] Use errorHandler from liblldCommon 2018-06-12 02:34:04 +00:00
unittests [Darwin] Use errorHandler from liblldCommon 2018-06-12 02:34:04 +00:00
utils Add a script to run various benchmarks and send the result to lnt. 2017-11-14 16:40:30 +00:00
wasm [WebAssembly] Add --export-all flag 2018-06-07 01:27:07 +00:00
.arcconfig [lld] Set up .arcconfig to point to new Diffusion LLD repository 2017-12-06 20:56:23 +00:00
.clang-format
.gitignore
CMakeLists.txt [WebAssembly] Initial wasm linker implementation 2017-11-17 18:14:09 +00:00
CODE_OWNERS.TXT [WebAssembly] Initial wasm linker implementation 2017-11-17 18:14:09 +00:00
LICENSE.TXT
README.md Note that the test .tar.xz has been updated. 2017-12-22 19:37:32 +00:00

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.

Benchmarking

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.