Simon Atanasyan | 5f0a1c1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 1 | // Check passing options to the assembler for MIPS targets. |
| 2 | // |
| 3 | // RUN: %clang -target mips-linux-gnu -### \ |
| 4 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 5 | // RUN: | FileCheck -check-prefix=MIPS32-EB-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 6 | // MIPS32-EB-AS: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
| 7 | // MIPS32-EB-AS-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-KPIC" |
Simon Atanasyan | 1f0646e | 2012-05-29 19:07:33 +0000 | [diff] [blame] | 8 | // |
| 9 | // RUN: %clang -target mips-linux-gnu -### \ |
| 10 | // RUN: -no-integrated-as -fPIC -c %s 2>&1 \ |
| 11 | // RUN: | FileCheck -check-prefix=MIPS32-EB-PIC %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 12 | // MIPS32-EB-PIC: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
Simon Atanasyan | 125aa1f | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 13 | // MIPS32-EB-PIC: "-KPIC" |
Simon Atanasyan | 5f0a1c1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 14 | // |
| 15 | // RUN: %clang -target mipsel-linux-gnu -### \ |
| 16 | // RUN: -no-integrated-as -c %s 2>&1 \ |
Simon Atanasyan | e9616a4 | 2013-02-27 14:55:49 +0000 | [diff] [blame] | 17 | // RUN: | FileCheck -check-prefix=MIPS32-DEF-EL-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 18 | // MIPS32-DEF-EL-AS: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EL" |
Simon Atanasyan | 5f0a1c1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 19 | // |
| 20 | // RUN: %clang -target mips64-linux-gnu -### \ |
| 21 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 22 | // RUN: | FileCheck -check-prefix=MIPS64-EB-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 23 | // MIPS64-EB-AS: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "64" "-EB" |
Simon Atanasyan | 5f0a1c1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 24 | // |
| 25 | // RUN: %clang -target mips64el-linux-gnu -### \ |
| 26 | // RUN: -no-integrated-as -c %s 2>&1 \ |
Simon Atanasyan | e9616a4 | 2013-02-27 14:55:49 +0000 | [diff] [blame] | 27 | // RUN: | FileCheck -check-prefix=MIPS64-DEF-EL-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 28 | // MIPS64-DEF-EL-AS: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "64" "-EL" |
Simon Atanasyan | 073a780 | 2012-04-07 22:31:29 +0000 | [diff] [blame] | 29 | // |
| 30 | // RUN: %clang -target mips-linux-gnu -mabi=eabi -### \ |
| 31 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 32 | // RUN: | FileCheck -check-prefix=MIPS-EABI %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 33 | // MIPS-EABI: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "eabi" "-EB" |
Simon Atanasyan | 073a780 | 2012-04-07 22:31:29 +0000 | [diff] [blame] | 34 | // |
| 35 | // RUN: %clang -target mips64-linux-gnu -mabi=n32 -### \ |
| 36 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 37 | // RUN: | FileCheck -check-prefix=MIPS-N32 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 38 | // MIPS-N32: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "n32" "-EB" |
Simon Atanasyan | 89d83ff | 2012-09-10 08:32:41 +0000 | [diff] [blame] | 39 | // |
Simon Atanasyan | e9616a4 | 2013-02-27 14:55:49 +0000 | [diff] [blame] | 40 | // RUN: %clang -target mipsel-linux-gnu -mabi=32 -### \ |
| 41 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 42 | // RUN: | FileCheck -check-prefix=MIPS32-EL-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 43 | // MIPS32-EL-AS: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EL" |
Simon Atanasyan | e9616a4 | 2013-02-27 14:55:49 +0000 | [diff] [blame] | 44 | // |
| 45 | // RUN: %clang -target mips64el-linux-gnu -mabi=64 -### \ |
| 46 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 47 | // RUN: | FileCheck -check-prefix=MIPS64-EL-AS %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 48 | // MIPS64-EL-AS: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "64" "-EL" |
Simon Atanasyan | e9616a4 | 2013-02-27 14:55:49 +0000 | [diff] [blame] | 49 | // |
Simon Atanasyan | 89d83ff | 2012-09-10 08:32:41 +0000 | [diff] [blame] | 50 | // RUN: %clang -target mips-linux-gnu -march=mips32r2 -### \ |
| 51 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 52 | // RUN: | FileCheck -check-prefix=MIPS-32R2 %s |
| 53 | // MIPS-32R2: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
Simon Atanasyan | 8e1c598 | 2012-09-21 20:19:32 +0000 | [diff] [blame] | 54 | // |
| 55 | // RUN: %clang -target mips-linux-gnu -mips32 -### \ |
| 56 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 57 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-32 %s |
| 58 | // MIPS-ALIAS-32: as{{(.exe)?}}" "-march" "mips32" "-mabi" "32" "-EB" |
| 59 | // |
| 60 | // RUN: %clang -target mips-linux-gnu -mips32r2 -### \ |
| 61 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 62 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-32R2 %s |
| 63 | // MIPS-ALIAS-32R2: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
| 64 | // |
| 65 | // RUN: %clang -target mips-linux-gnu -mips64 -### \ |
| 66 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 67 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-64 %s |
| 68 | // MIPS-ALIAS-64: as{{(.exe)?}}" "-march" "mips64" "-mabi" "64" "-EB" |
| 69 | // |
| 70 | // RUN: %clang -target mips-linux-gnu -mips64r2 -### \ |
| 71 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 72 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-64R2 %s |
| 73 | // MIPS-ALIAS-64R2: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "64" "-EB" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 74 | // |
| 75 | // RUN: %clang -target mips-linux-gnu -mno-mips16 -mips16 -### \ |
| 76 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 77 | // RUN: | FileCheck -check-prefix=MIPS-16 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 78 | // MIPS-16: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mips16" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 79 | // |
| 80 | // RUN: %clang -target mips-linux-gnu -mips16 -mno-mips16 -### \ |
| 81 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 82 | // RUN: | FileCheck -check-prefix=MIPS-N16 %s |
| 83 | // MIPS-N16: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 84 | // MIPS-N16-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mips16" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 85 | // |
| 86 | // RUN: %clang -target mips-linux-gnu -mno-micromips -mmicromips -### \ |
| 87 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 88 | // RUN: | FileCheck -check-prefix=MIPS-MICRO %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 89 | // MIPS-MICRO: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mmicromips" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 90 | // |
| 91 | // RUN: %clang -target mips-linux-gnu -mmicromips -mno-micromips -### \ |
| 92 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 93 | // RUN: | FileCheck -check-prefix=MIPS-NMICRO %s |
| 94 | // MIPS-NMICRO: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 95 | // MIPS-NMICRO-NOT: {{[A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mmicromips" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 96 | // |
| 97 | // RUN: %clang -target mips-linux-gnu -mno-dsp -mdsp -### \ |
| 98 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 99 | // RUN: | FileCheck -check-prefix=MIPS-DSP %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 100 | // MIPS-DSP: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mdsp" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 101 | // |
| 102 | // RUN: %clang -target mips-linux-gnu -mdsp -mno-dsp -### \ |
| 103 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 104 | // RUN: | FileCheck -check-prefix=MIPS-NDSP %s |
| 105 | // MIPS-NDSP: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 106 | // MIPS-NDSP-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mdsp" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 107 | // |
| 108 | // RUN: %clang -target mips-linux-gnu -mno-dspr2 -mdspr2 -### \ |
| 109 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 110 | // RUN: | FileCheck -check-prefix=MIPS-DSPR2 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 111 | // MIPS-DSPR2: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mdspr2" |
Simon Atanasyan | 9dbfc61 | 2013-04-30 07:47:13 +0000 | [diff] [blame] | 112 | // |
| 113 | // RUN: %clang -target mips-linux-gnu -mdspr2 -mno-dspr2 -### \ |
| 114 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 115 | // RUN: | FileCheck -check-prefix=MIPS-NDSPR2 %s |
| 116 | // MIPS-NDSPR2: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 117 | // MIPS-NDSPR2-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mdspr2" |
Simon Atanasyan | fc12c4a | 2013-09-24 09:09:16 +0000 | [diff] [blame] | 118 | // |
| 119 | // RUN: %clang -target mips-linux-gnu -mnan=legacy -mnan=2008 -### \ |
| 120 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 121 | // RUN: | FileCheck -check-prefix=MIPS-NAN2008 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 122 | // MIPS-NAN2008: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mnan=2008" |
Simon Atanasyan | fc12c4a | 2013-09-24 09:09:16 +0000 | [diff] [blame] | 123 | // |
| 124 | // RUN: %clang -target mips-linux-gnu -mnan=2008 -mnan=legacy -### \ |
| 125 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 126 | // RUN: | FileCheck -check-prefix=MIPS-NAN-LEGACY %s |
| 127 | // MIPS-NAN-LEGACY: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 128 | // MIPS-NAN-LEGACY-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mnan={{.*}}" |
Daniel Sanders | 6c5c3ad | 2013-12-02 10:00:07 +0000 | [diff] [blame] | 129 | // |
| 130 | // RUN: %clang -target mips-linux-gnu -mfp64 -mfp32 -### \ |
| 131 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 132 | // RUN: | FileCheck -check-prefix=MIPS-MFP32 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 133 | // MIPS-MFP32: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mfp32" |
Daniel Sanders | 6c5c3ad | 2013-12-02 10:00:07 +0000 | [diff] [blame] | 134 | // |
| 135 | // RUN: %clang -target mips-linux-gnu -mfp32 -mfp64 -### \ |
| 136 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 137 | // RUN: | FileCheck -check-prefix=MIPS-MFP64 %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 138 | // MIPS-MFP64: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mfp64" |
Daniel Sanders | 0d5d6ff | 2013-12-02 10:14:43 +0000 | [diff] [blame] | 139 | // |
| 140 | // RUN: %clang -target mips-linux-gnu -mno-msa -mmsa -### \ |
| 141 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 142 | // RUN: | FileCheck -check-prefix=MIPS-MSA %s |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 143 | // MIPS-MSA: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" "-mmsa" |
Daniel Sanders | 0d5d6ff | 2013-12-02 10:14:43 +0000 | [diff] [blame] | 144 | // |
| 145 | // RUN: %clang -target mips-linux-gnu -mmsa -mno-msa -### \ |
| 146 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 147 | // RUN: | FileCheck -check-prefix=MIPS-NMSA %s |
| 148 | // MIPS-NMSA: as{{(.exe)?}}" |
Stephen Hines | 651f13c | 2014-04-23 16:59:28 -0700 | [diff] [blame^] | 149 | // MIPS-NMSA-NOT: "{{[ A-Za-z\\\/]*}}as{{(.exe)?}}{{.*}}"-mmsa" |