aboutsummaryrefslogtreecommitdiff
path: root/test/Driver/aarch64-cpus.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Driver/aarch64-cpus.c')
-rw-r--r--test/Driver/aarch64-cpus.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/Driver/aarch64-cpus.c b/test/Driver/aarch64-cpus.c
new file mode 100644
index 000000000000..799ce1042a0e
--- /dev/null
+++ b/test/Driver/aarch64-cpus.c
@@ -0,0 +1,10 @@
+// Check target CPUs are correctly passed.
+
+// RUN: %clang -target aarch64 -### -c %s 2>&1 | FileCheck -check-prefix=GENERIC %s
+// GENERIC: "-cc1"{{.*}} "-triple" "aarch64{{.*}}" "-target-cpu" "generic"
+
+// RUN: %clang -target aarch64 -mcpu=cortex-a53 -### -c %s 2>&1 | FileCheck -check-prefix=CA53 %s
+// CA53: "-cc1"{{.*}} "-triple" "aarch64{{.*}}" "-target-cpu" "cortex-a53"
+
+// RUN: %clang -target aarch64 -mcpu=cortex-a57 -### -c %s 2>&1 | FileCheck -check-prefix=CA57 %s
+// CA57: "-cc1"{{.*}} "-triple" "aarch64{{.*}}" "-target-cpu" "cortex-a57"