================
@@ -1,15 +1,20 @@
-// RUN: %clang -target i386-unknown-linux -fstack-clash-protection -### %s 
2>&1 | FileCheck %s -check-prefix=SCP-i386
-// RUN: %clang -target i386-unknown-linux -fno-stack-clash-protection 
-fstack-clash-protection -### %s 2>&1 | FileCheck %s -check-prefix=SCP-i386
-// RUN: %clang -target i386-unknown-linux -fstack-clash-protection 
-fno-stack-clash-protection -### %s 2>&1 | FileCheck %s 
-check-prefix=SCP-i386-NO
-// SCP-i386: "-fstack-clash-protection"
-// SCP-i386-NO-NOT: "-fstack-clash-protection"
-
-// RUN: %clang -target x86_64-scei-linux -fstack-clash-protection -### %s 2>&1 
| FileCheck %s -check-prefix=SCP-x86
-// RUN: %clang -target x86_64-unknown-freebsd -fstack-clash-protection -### %s 
2>&1 | FileCheck %s -check-prefix=SCP-x86
-// SCP-x86: "-fstack-clash-protection"
-
-// RUN: %clang -target armv7k-apple-linux -fstack-clash-protection -### %s 
2>&1 | FileCheck %s -check-prefix=SCP-armv7
-// SCP-armv7-NOT: "-fstack-clash-protection"
+// RUN: %clang -target i386-unknown-linux -fstack-clash-protection -### %s 
2>&1 | FileCheck %s --check-prefix=ENABLED
+// RUN: %clang -target i386-unknown-linux -fno-stack-clash-protection 
-fstack-clash-protection -### %s 2>&1 | FileCheck %s --check-prefix=ENABLED
+// RUN: %clang -target i386-unknown-linux -fstack-clash-protection 
-fno-stack-clash-protection -### %s 2>&1 | FileCheck %s --check-prefix=DISABLED 
--implicit-check-not='"-fstack-clash-protection"'
+
+// RUN: %clang -target x86_64-scei-linux -fstack-clash-protection -### %s 2>&1 
| FileCheck %s --check-prefix=ENABLED
+// RUN: %clang -target x86_64-unknown-freebsd -fstack-clash-protection -### %s 
2>&1 | FileCheck %s --check-prefix=ENABLED
+
+// RUN: %clang -target x86_64-unknown-linux -### %s 2>&1 | FileCheck %s 
--check-prefix=DISABLED --implicit-check-not='"-fstack-clash-protection"'
+
+// RUN: %clang -target aarch64-linux-android -### %s 2>&1 | FileCheck %s 
--check-prefix=ENABLED
+// 32-bit Arm does not support stack clash protection.
+// RUN: %clang -target armv7-linux-androideabi -### %s 2>&1 | FileCheck %s 
--check-prefix=DISABLED --implicit-check-not='"-fstack-clash-protection"'
+
+// ENABLED: "-fstack-clash-protection"
+// DISABLED: "-cc1"
----------------
Alearner12 wrote:

--implicit-check-not isn't a check string on its own, so DISABLED , needs at 
least one directive or filecheck errors with no check strings found. -cc1 is 
that anchor, and it also makes the negative meaningful it proves a cc1 job was 
actually emitted, so the test can't pass just bcoz clang bailed out early and 
printed nothing.

https://github.com/llvm/llvm-project/pull/209279
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to