Author: Jez Ng Date: 2021-03-01T11:29:42-08:00 New Revision: 922de2574c17a755279358be928e5343dcf56c56
URL: https://github.com/llvm/llvm-project/commit/922de2574c17a755279358be928e5343dcf56c56 DIFF: https://github.com/llvm/llvm-project/commit/922de2574c17a755279358be928e5343dcf56c56.diff LOG: [lld-macho] Partial revert of D95204 Trying to unbreak https://lab.llvm.org/buildbot/#/builders/57/builds/4753 I'm not able to repro the failures locally so... here's hoping Added: clang/test/Driver/Inputs/lld/ld64.lld.darwinnew Modified: clang/lib/Driver/ToolChain.cpp clang/test/Driver/darwin-ld-demangle-lld.c clang/test/Driver/darwin-ld-platform-version-ios.c clang/test/Driver/darwin-ld-platform-version-macos.c clang/test/Driver/darwin-ld-platform-version-tvos.c clang/test/Driver/darwin-ld-platform-version-watchos.c Removed: clang/test/Driver/Inputs/lld/ld64.lld.darwinold ################################################################################ diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp index e6a6fe2cb062..f8b03b635dd7 100644 --- a/clang/lib/Driver/ToolChain.cpp +++ b/clang/lib/Driver/ToolChain.cpp @@ -620,11 +620,11 @@ std::string ToolChain::GetLinkerPath(bool *LinkerIsLLD, std::string LinkerPath(GetProgramPath(LinkerName.c_str())); if (llvm::sys::fs::can_execute(LinkerPath)) { - // FIXME: Remove LinkerIsLLDDarwinNew once there's only one MachO lld. + // FIXME: Remove lld.darwinnew here once it's the only MachO lld. if (LinkerIsLLD) - *LinkerIsLLD = UseLinker == "lld" || UseLinker == "lld.darwinold"; + *LinkerIsLLD = UseLinker == "lld" || UseLinker == "lld.darwinnew"; if (LinkerIsLLDDarwinNew) - *LinkerIsLLDDarwinNew = UseLinker == "lld"; + *LinkerIsLLDDarwinNew = UseLinker == "lld.darwinnew"; return LinkerPath; } } diff --git a/clang/test/Driver/Inputs/lld/ld64.lld.darwinold b/clang/test/Driver/Inputs/lld/ld64.lld.darwinnew similarity index 100% rename from clang/test/Driver/Inputs/lld/ld64.lld.darwinold rename to clang/test/Driver/Inputs/lld/ld64.lld.darwinnew diff --git a/clang/test/Driver/darwin-ld-demangle-lld.c b/clang/test/Driver/darwin-ld-demangle-lld.c index 9610f6bc1016..84facc8d1539 100644 --- a/clang/test/Driver/darwin-ld-demangle-lld.c +++ b/clang/test/Driver/darwin-ld-demangle-lld.c @@ -1,13 +1,12 @@ // With -fuse-ld=lld, -demangle is always passed to the linker on Darwin. // REQUIRES: shell -// FIXME: Remove this test case when we remove the lld.darwinold backend. // RUN: %clang --target=x86_64-apple-darwin -### \ -// RUN: -fuse-ld=lld.darwinold -B%S/Inputs/lld -mlinker-version=0 %s 2>&1 \ +// RUN: -fuse-ld=lld -B%S/Inputs/lld -mlinker-version=0 %s 2>&1 \ // RUN: | FileCheck %s - +// FIXME: Remove ld.darwinnew once it's the default (and only) mach-o lld. // RUN: %clang --target=x86_64-apple-darwin -### \ -// RUN: -fuse-ld=lld -B%S/Inputs/lld -mlinker-version=0 %s 2>&1 \ +// RUN: -fuse-ld=lld.darwinnew -B%S/Inputs/lld -mlinker-version=0 %s 2>&1 \ // RUN: | FileCheck %s // CHECK: "-demangle" diff --git a/clang/test/Driver/darwin-ld-platform-version-ios.c b/clang/test/Driver/darwin-ld-platform-version-ios.c index bd518c315149..d03e46b5776d 100644 --- a/clang/test/Driver/darwin-ld-platform-version-ios.c +++ b/clang/test/Driver/darwin-ld-platform-version-ios.c @@ -1,6 +1,6 @@ // RUN: touch %t.o -// RUN: %clang -target arm64-apple-ios12.3 -fuse-ld=lld.darwinold \ +// RUN: %clang -target arm64-apple-ios12.3 -fuse-ld= \ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=0 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s @@ -12,7 +12,7 @@ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=520 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-NEW %s -// RUN: %clang -target arm64-apple-ios12.3 -fuse-ld=lld \ +// RUN: %clang -target arm64-apple-ios12.3 -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=0 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-NEW %s @@ -20,7 +20,7 @@ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=520 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=SIMUL %s -// RUN: %clang -target x86_64-apple-ios13-simulator -fuse-ld=lld \ +// RUN: %clang -target x86_64-apple-ios13-simulator -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=0 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=SIMUL %s diff --git a/clang/test/Driver/darwin-ld-platform-version-macos.c b/clang/test/Driver/darwin-ld-platform-version-macos.c index 5a2510acb646..1954deea7b93 100644 --- a/clang/test/Driver/darwin-ld-platform-version-macos.c +++ b/clang/test/Driver/darwin-ld-platform-version-macos.c @@ -1,10 +1,10 @@ // RUN: touch %t.o -// RUN: %clang -target x86_64-apple-macos10.13 -fuse-ld=lld.darwinold \ +// RUN: %clang -target x86_64-apple-macos10.13 -fuse-ld= \ // RUN: -isysroot %S/Inputs/MacOSX10.14.sdk -mlinker-version=0 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s -// RUN: %clang -target x86_64-apple-macos10.13 -fuse-ld=lld \ +// RUN: %clang -target x86_64-apple-macos10.13 -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/MacOSX10.14.sdk -mlinker-version=0 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-NEW %s @@ -21,7 +21,7 @@ // RUN: -isysroot %S/Inputs/MacOSX10.14.sdk -mlinker-version=400 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=ARM64_OLD %s -// RUN: %clang -target arm64-apple-macos10.13 -fuse-ld=lld \ +// RUN: %clang -target arm64-apple-macos10.13 -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/MacOSX10.14.sdk -mlinker-version=400 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=ARM64_NEW %s diff --git a/clang/test/Driver/darwin-ld-platform-version-tvos.c b/clang/test/Driver/darwin-ld-platform-version-tvos.c index bf57c26bf25c..beaa46b32f6f 100644 --- a/clang/test/Driver/darwin-ld-platform-version-tvos.c +++ b/clang/test/Driver/darwin-ld-platform-version-tvos.c @@ -1,6 +1,6 @@ // RUN: touch %t.o -// RUN: %clang -target arm64-apple-tvos12.3 -fuse-ld=lld.darwinold \ +// RUN: %clang -target arm64-apple-tvos12.3 -fuse-ld= \ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=0 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s @@ -8,7 +8,7 @@ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=400 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s -// RUN: %clang -target arm64-apple-tvos12.3 -fuse-ld=lld \ +// RUN: %clang -target arm64-apple-tvos12.3 -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/iPhoneOS13.0.sdk -mlinker-version=0 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-NEW %s diff --git a/clang/test/Driver/darwin-ld-platform-version-watchos.c b/clang/test/Driver/darwin-ld-platform-version-watchos.c index 639c937d6be5..ab03fefce696 100644 --- a/clang/test/Driver/darwin-ld-platform-version-watchos.c +++ b/clang/test/Driver/darwin-ld-platform-version-watchos.c @@ -1,6 +1,6 @@ // RUN: touch %t.o -// RUN: %clang -target arm64_32-apple-watchos5.2 -fuse-ld=lld.darwinold \ +// RUN: %clang -target arm64_32-apple-watchos5.2 -fuse-ld= \ // RUN: -isysroot %S/Inputs/WatchOS6.0.sdk -mlinker-version=0 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s @@ -8,7 +8,7 @@ // RUN: -isysroot %S/Inputs/WatchOS6.0.sdk -mlinker-version=400 \ // RUN: -### %t.o 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-OLD %s -// RUN: %clang -target arm64_32-apple-watchos5.2 -fuse-ld=lld \ +// RUN: %clang -target arm64_32-apple-watchos5.2 -fuse-ld=lld.darwinnew \ // RUN: -isysroot %S/Inputs/WatchOS6.0.sdk -mlinker-version=0 \ // RUN: -### %t.o -B%S/Inputs/lld 2>&1 \ // RUN: | FileCheck --check-prefix=LINKER-NEW %s _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits