Index: clang/test/Driver/hexagon-toolchain-elf.c =================================================================== --- clang/test/Driver/hexagon-toolchain-elf.c +++ clang/test/Driver/hexagon-toolchain-elf.c @@ -57,7 +57,7 @@ // ----------------------------------------------------------------------------- // Test -mcpu= -mv // ----------------------------------------------------------------------------- -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv4 \ // RUN: %s 2>&1 \ @@ -65,7 +65,7 @@ // CHECK020: "-cc1" {{.*}} "-target-cpu" "hexagonv4" // CHECK020: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v4/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv5 \ // RUN: %s 2>&1 \ @@ -73,7 +73,7 @@ // CHECK021: "-cc1" {{.*}} "-target-cpu" "hexagonv5" // CHECK021: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v5/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv55 \ // RUN: %s 2>&1 \ @@ -81,7 +81,7 @@ // CHECK022: "-cc1" {{.*}} "-target-cpu" "hexagonv55" // CHECK022: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v55/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: %s 2>&1 \ @@ -89,7 +89,7 @@ // CHECK023: "-cc1" {{.*}} "-target-cpu" "hexagonv60" // CHECK023: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v60/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv62 \ // RUN: %s 2>&1 \ @@ -97,7 +97,7 @@ // CHECK024: "-cc1" {{.*}} "-target-cpu" "hexagonv62" // CHECK024: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v62/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv65 \ // RUN: %s 2>&1 \ @@ -105,7 +105,7 @@ // CHECK025: "-cc1" {{.*}} "-target-cpu" "hexagonv65" // CHECK025: hexagon-link{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v65/crt0 -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -O3 \ // RUN: %s 2>&1 \ @@ -113,7 +113,7 @@ // CHECK026-NOT: "-ffp-contract=fast" // CHECK026: hexagon-link -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -O3 -ffp-contract=off \ // RUN: %s 2>&1 \ @@ -128,7 +128,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // Defaults for C // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: %s 2>&1 \ @@ -149,7 +149,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // Defaults for C++ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clangxx -### -target hexagon-unknown-elf \ +// RUN: %clangxx -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: %s 2>&1 \ @@ -171,7 +171,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // Additional Libraries (-L) // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -Lone -L two -L three \ @@ -194,7 +194,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // -static, -shared // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -static \ @@ -212,7 +212,7 @@ // CHECK033: "--start-group" "-lstandalone" "-lc" "-lgcc" "--end-group" // CHECK033: "{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v60/fini.o" -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -shared \ @@ -235,7 +235,7 @@ // CHECK034: "--end-group" // CHECK034: "{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v60/G0/pic/finiS.o" -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -shared \ @@ -262,7 +262,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // -nostdlib, -nostartfiles, -nodefaultlibs // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clangxx -### -target hexagon-unknown-elf \ +// RUN: %clangxx -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -nostdlib \ @@ -285,7 +285,7 @@ // CHECK036-NOT: "--end-group" // CHECK036-NOT: fini.o -// RUN: %clangxx -### -target hexagon-unknown-elf \ +// RUN: %clangxx -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -nostartfiles \ @@ -308,7 +308,7 @@ // CHECK037: "--end-group" // CHECK037-NOT: fini.o -// RUN: %clangxx -### -target hexagon-unknown-elf \ +// RUN: %clangxx -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -nodefaultlibs \ @@ -334,7 +334,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // -moslib // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -moslib=first -moslib=second \ @@ -356,7 +356,7 @@ // CHECK039: "-lc" "-lgcc" "--end-group" // CHECK039: "{{.*}}/Inputs/hexagon_tree/Tools/bin/../target/hexagon/lib/v60/fini.o" -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -moslib=first -moslib=second -moslib=standalone \ @@ -381,7 +381,7 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // Other args to pass to linker // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// RUN: %clangxx -### -target hexagon-unknown-elf \ +// RUN: %clangxx -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -s \ @@ -410,7 +410,7 @@ // ----------------------------------------------------------------------------- // pic, small data threshold // ----------------------------------------------------------------------------- -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: %s 2>&1 \ @@ -419,13 +419,13 @@ // CHECK040-NEXT: hexagon-link // CHECK040-NOT: "-G{{[0-9]+}}" -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -fpic \ // RUN: %s 2>&1 \ // RUN: | FileCheck -check-prefix=CHECK041 %s -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -fPIC \ @@ -438,19 +438,19 @@ // CHECK041-NEXT: hexagon-link // CHECK041: "-G0" -// RUN: %clang -### -target hexagon-unknown-elf -fno-integrated-as \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld -fno-integrated-as \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -G=8 \ // RUN: %s 2>&1 \ // RUN: | FileCheck -check-prefix=CHECK042 %s -// RUN: %clang -### -target hexagon-unknown-elf -fno-integrated-as \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld -fno-integrated-as \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -G 8 \ // RUN: %s 2>&1 \ // RUN: | FileCheck -check-prefix=CHECK042 %s -// RUN: %clang -### -target hexagon-unknown-elf -fno-integrated-as \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld -fno-integrated-as \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -msmall-data-threshold=8 \ @@ -467,7 +467,7 @@ // ----------------------------------------------------------------------------- // pie // ----------------------------------------------------------------------------- -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -pie \ @@ -477,7 +477,7 @@ // CHECK050-NEXT: hexagon-link // CHECK050: "-pie" -// RUN: %clang -### -target hexagon-unknown-elf \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -pie -shared \ @@ -490,7 +490,7 @@ // ----------------------------------------------------------------------------- // Test Assembler related args // ----------------------------------------------------------------------------- -// RUN: %clang -### -target hexagon-unknown-elf -fno-integrated-as \ +// RUN: %clang -### -target hexagon-unknown-elf -fuse-ld=ld -fno-integrated-as \ // RUN: -ccc-install-dir %S/Inputs/hexagon_tree/Tools/bin \ // RUN: -mcpu=hexagonv60 \ // RUN: -gdwarf-2 \ Index: clang/test/Driver/linux-ld.c =================================================================== --- clang/test/Driver/linux-ld.c +++ clang/test/Driver/linux-ld.c @@ -877,7 +877,7 @@ // Check that we do not pass --hash-style=gnu or --hash-style=both to // hexagon linux linker // RUN: %clang %s -### -o %t.o 2>&1 \ -// RUN: --target=hexagon-linux-gnu \ +// RUN: --target=hexagon-linux-gnu -fuse-ld=ld \ // RUN: | FileCheck --check-prefix=CHECK-HEXAGON %s // CHECK-HEXAGON: "{{.*}}hexagon-link{{(.exe)?}}" // CHECK-HEXAGON-NOT: "--hash-style={{gnu|both}}"