Ed Schouten | fc79d2c | 2016-03-29 21:13:53 +0000 | [diff] [blame] | 1 | // RUN: %clangxx %s -### -target x86_64-unknown-cloudabi 2>&1 | FileCheck %s -check-prefix=SAFESTACK |
| 2 | // SAFESTACK: "-cc1" "-triple" "x86_64-unknown-cloudabi" {{.*}} "-ffunction-sections" "-fdata-sections" {{.*}} "-fsanitize=safe-stack" |
Ed Schouten | 610adae | 2016-08-11 20:03:22 +0000 | [diff] [blame^] | 3 | // SAFESTACK: "-Bstatic" "--no-dynamic-linker" "-pie" "-zrelro" "--eh-frame-hdr" "--gc-sections" "-o" "a.out" "crt0.o" "crtbegin.o" "{{.*}}" "{{.*}}" "-lc++" "-lc++abi" "-lunwind" "-lc" "-lcompiler_rt" "crtend.o" |
Ed Schouten | fc79d2c | 2016-03-29 21:13:53 +0000 | [diff] [blame] | 4 | |
Ed Schouten | 610adae | 2016-08-11 20:03:22 +0000 | [diff] [blame^] | 5 | // RUN: %clangxx %s -### -target x86_64-unknown-cloudabi -fno-sanitize=safe-stack 2>&1 | FileCheck %s -check-prefix=NOSAFESTACK |
Ed Schouten | fc79d2c | 2016-03-29 21:13:53 +0000 | [diff] [blame] | 6 | // NOSAFESTACK: "-cc1" "-triple" "x86_64-unknown-cloudabi" {{.*}} "-ffunction-sections" "-fdata-sections" |
| 7 | // NOSAFESTACK-NOT: "-fsanitize=safe-stack" |
Ed Schouten | 610adae | 2016-08-11 20:03:22 +0000 | [diff] [blame^] | 8 | // NOSAFESTACK: "-Bstatic" "--no-dynamic-linker" "-pie" "-zrelro" "--eh-frame-hdr" "--gc-sections" "-o" "a.out" "crt0.o" "crtbegin.o" "{{.*}}" "{{.*}}" "-lc++" "-lc++abi" "-lunwind" "-lc" "-lcompiler_rt" "crtend.o" |
| 9 | |
| 10 | // PIE shouldn't be enabled on i686. Just on architectures that provide |
| 11 | // PC-relative addressing. |
| 12 | // RUN: %clangxx %s -### -target i686-unknown-cloudabi 2>&1 | FileCheck %s -check-prefix=NOPIE |
| 13 | // NOPIE: "-cc1" "-triple" "i686-unknown-cloudabi" {{.*}} "-ffunction-sections" "-fdata-sections" {{.*}} "-fsanitize=safe-stack" |
| 14 | // NOPIE: "-Bstatic" "--no-dynamic-linker" "--eh-frame-hdr" "--gc-sections" "-o" "a.out" "crt0.o" "crtbegin.o" "{{.*}}" "{{.*}}" "-lc++" "-lc++abi" "-lunwind" "-lc" "-lcompiler_rt" "crtend.o" |