diff options
author | Nico Weber <thakis@chromium.org> | 2020-12-01 11:46:15 -0500 |
---|---|---|
committer | Nico Weber <thakis@chromium.org> | 2020-12-01 12:07:56 -0500 |
commit | b99e2b8b14f4ba50f9eb80bd5a2c1824099a7f96 (patch) | |
tree | c9e74722df58931fcd6e2f47acc8a8cd03abe2af | |
parent | [LV] Epilogue Vectorization with Optimal Control Flow (diff) | |
download | llvm-project-b99e2b8b14f4ba50f9eb80bd5a2c1824099a7f96.tar.gz llvm-project-b99e2b8b14f4ba50f9eb80bd5a2c1824099a7f96.tar.bz2 llvm-project-b99e2b8b14f4ba50f9eb80bd5a2c1824099a7f96.zip |
clang/darwin: Use response files with ld64.lld.darwinnew
The new MachO lld just grew support for response files in D92149, so let
the clang driver use it.
Differential Revision: https://reviews.llvm.org/D92399
-rw-r--r-- | clang/lib/Driver/ToolChains/Darwin.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/lib/Driver/ToolChains/Darwin.cpp b/clang/lib/Driver/ToolChains/Darwin.cpp index db3d57a48098..f1846a573914 100644 --- a/clang/lib/Driver/ToolChains/Darwin.cpp +++ b/clang/lib/Driver/ToolChains/Darwin.cpp @@ -697,8 +697,10 @@ void darwin::Linker::ConstructJob(Compilation &C, const JobAction &JA, } } - ResponseFileSupport ResponseSupport = ResponseFileSupport::AtFileUTF8(); - if (Version[0] < 607) { + ResponseFileSupport ResponseSupport; + if (Version[0] >= 607 || LinkerIsLLDDarwinNew) { + ResponseSupport = ResponseFileSupport::AtFileUTF8(); + } else { // For older versions of the linker, use the legacy filelist method instead. ResponseSupport = {ResponseFileSupport::RF_FileList, llvm::sys::WEM_UTF8, "-filelist"}; |