Simon Atanasyan | a80313a | 2012-08-28 11:17:20 +0000 | [diff] [blame] | 1 | // REQUIRES: mips-registered-target |
| 2 | // |
Simon Atanasyan | 2390aa1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 3 | // Check passing options to the assembler for MIPS targets. |
| 4 | // |
| 5 | // RUN: %clang -target mips-linux-gnu -### \ |
| 6 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 7 | // RUN: | FileCheck -check-prefix=MIPS32-EB-AS %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 8 | // MIPS32-EB-AS: as{{(.exe)?}}" "-march" "mips32" "-mabi" "32" "-EB" |
| 9 | // MIPS32-EB-AS-NOT: "-KPIC" |
Simon Atanasyan | 217dc2d | 2012-05-29 19:07:33 +0000 | [diff] [blame] | 10 | // |
| 11 | // RUN: %clang -target mips-linux-gnu -### \ |
| 12 | // RUN: -no-integrated-as -fPIC -c %s 2>&1 \ |
| 13 | // RUN: | FileCheck -check-prefix=MIPS32-EB-PIC %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 14 | // MIPS32-EB-PIC: as{{(.exe)?}}" "-march" "mips32" "-mabi" "32" "-EB" |
| 15 | // MIPS32-EB-PIC: "-KPIC" |
Simon Atanasyan | 2390aa1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 16 | // |
| 17 | // RUN: %clang -target mipsel-linux-gnu -### \ |
| 18 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 19 | // RUN: | FileCheck -check-prefix=MIPS32-EL-AS %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 20 | // MIPS32-EL-AS: as{{(.exe)?}}" "-march" "mips32" "-mabi" "32" "-EL" |
Simon Atanasyan | 2390aa1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 21 | // |
| 22 | // RUN: %clang -target mips64-linux-gnu -### \ |
| 23 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 24 | // RUN: | FileCheck -check-prefix=MIPS64-EB-AS %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 25 | // MIPS64-EB-AS: as{{(.exe)?}}" "-march" "mips64" "-mabi" "64" "-EB" |
Simon Atanasyan | 2390aa1 | 2012-04-06 19:15:24 +0000 | [diff] [blame] | 26 | // |
| 27 | // RUN: %clang -target mips64el-linux-gnu -### \ |
| 28 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 29 | // RUN: | FileCheck -check-prefix=MIPS64-EL-AS %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 30 | // MIPS64-EL-AS: as{{(.exe)?}}" "-march" "mips64" "-mabi" "64" "-EL" |
Simon Atanasyan | 571d7bd | 2012-04-07 22:31:29 +0000 | [diff] [blame] | 31 | // |
| 32 | // RUN: %clang -target mips-linux-gnu -mabi=eabi -### \ |
| 33 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 34 | // RUN: | FileCheck -check-prefix=MIPS-EABI %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 35 | // MIPS-EABI: as{{(.exe)?}}" "-march" "mips32" "-mabi" "eabi" "-EB" |
Simon Atanasyan | 571d7bd | 2012-04-07 22:31:29 +0000 | [diff] [blame] | 36 | // |
| 37 | // RUN: %clang -target mips64-linux-gnu -mabi=n32 -### \ |
| 38 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 39 | // RUN: | FileCheck -check-prefix=MIPS-N32 %s |
Simon Atanasyan | f438281 | 2012-07-05 11:30:19 +0000 | [diff] [blame] | 40 | // MIPS-N32: as{{(.exe)?}}" "-march" "mips64" "-mabi" "n32" "-EB" |
Simon Atanasyan | 464a7f7 | 2012-09-10 08:32:41 +0000 | [diff] [blame] | 41 | // |
| 42 | // RUN: %clang -target mips-linux-gnu -march=mips32r2 -### \ |
| 43 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 44 | // RUN: | FileCheck -check-prefix=MIPS-32R2 %s |
| 45 | // MIPS-32R2: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
Simon Atanasyan | 2efe53e | 2012-09-21 20:19:32 +0000 | [diff] [blame^] | 46 | // |
| 47 | // RUN: %clang -target mips-linux-gnu -mips32 -### \ |
| 48 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 49 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-32 %s |
| 50 | // MIPS-ALIAS-32: as{{(.exe)?}}" "-march" "mips32" "-mabi" "32" "-EB" |
| 51 | // |
| 52 | // RUN: %clang -target mips-linux-gnu -mips32r2 -### \ |
| 53 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 54 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-32R2 %s |
| 55 | // MIPS-ALIAS-32R2: as{{(.exe)?}}" "-march" "mips32r2" "-mabi" "32" "-EB" |
| 56 | // |
| 57 | // RUN: %clang -target mips-linux-gnu -mips64 -### \ |
| 58 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 59 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-64 %s |
| 60 | // MIPS-ALIAS-64: as{{(.exe)?}}" "-march" "mips64" "-mabi" "64" "-EB" |
| 61 | // |
| 62 | // RUN: %clang -target mips-linux-gnu -mips64r2 -### \ |
| 63 | // RUN: -no-integrated-as -c %s 2>&1 \ |
| 64 | // RUN: | FileCheck -check-prefix=MIPS-ALIAS-64R2 %s |
| 65 | // MIPS-ALIAS-64R2: as{{(.exe)?}}" "-march" "mips64r2" "-mabi" "64" "-EB" |