Daniel Dunbar | 5ce872f | 2011-03-18 20:14:03 +0000 | [diff] [blame] | 1 | // Check that we transparently fallback to llvm-gcc for i386 kexts, we don't |
| 2 | // support the ABI they use (yet). |
| 3 | |
Sebastian Pop | 9ec60df | 2012-01-20 22:01:23 +0000 | [diff] [blame] | 4 | // RUN: %clang -target i386-apple-darwin10 \ |
Daniel Dunbar | 5ce872f | 2011-03-18 20:14:03 +0000 | [diff] [blame] | 5 | // RUN: -fapple-kext -### -fsyntax-only %s 2> %t |
| 6 | // RUN: FileCheck --check-prefix=CHECK < %t %s |
| 7 | |
| 8 | // CHECK: cc1plus" |
| 9 | // CHECK: "-fapple-kext" |
Bob Wilson | a544aee | 2011-08-13 23:48:55 +0000 | [diff] [blame] | 10 | |
Sebastian Pop | 9ec60df | 2012-01-20 22:01:23 +0000 | [diff] [blame] | 11 | // RUN: %clang -target i386-apple-darwin10 \ |
Bob Wilson | a544aee | 2011-08-13 23:48:55 +0000 | [diff] [blame] | 12 | // RUN: -mkernel -### -fsyntax-only %s 2> %t |
| 13 | // RUN: FileCheck --check-prefix=CHECK-MKERNEL < %t %s |
| 14 | |
| 15 | // CHECK-MKERNEL: cc1plus" |
| 16 | // CHECK-MKERNEL: "-mkernel" |
Chad Rosier | 285f9a2 | 2011-08-17 18:24:55 +0000 | [diff] [blame] | 17 | |
Sebastian Pop | 9ec60df | 2012-01-20 22:01:23 +0000 | [diff] [blame] | 18 | // RUN: %clang -target i386-apple-darwin10 \ |
David Blaikie | 5f31f08 | 2011-10-18 05:54:07 +0000 | [diff] [blame] | 19 | // RUN: -Wno-self-assign -Wc++11-extensions -Wno-microsoft -Wmicrosoft -Wvla \ |
Chad Rosier | 8071797 | 2011-08-26 18:30:43 +0000 | [diff] [blame] | 20 | // RUN: -faltivec -mthumb -mcpu=G4 -mlongcall -mno-longcall -msoft-float \ |
Chad Rosier | 285f9a2 | 2011-08-17 18:24:55 +0000 | [diff] [blame] | 21 | // RUN: -fapple-kext -### -fsyntax-only %s 2> %t |
| 22 | // RUN: FileCheck --check-prefix=CHECK-UNSUPPORTED < %t %s |
| 23 | |
| 24 | // CHECK-UNSUPPORTED: cc1plus" |
| 25 | // CHECK-UNSUPPORTED-NOT: "-Wno-self-assign" |
David Blaikie | 5f31f08 | 2011-10-18 05:54:07 +0000 | [diff] [blame] | 26 | // CHECK-UNSUPPORTED-NOT: "-Wc++11-extensions" |
Chad Rosier | 04225c1 | 2011-08-18 01:18:28 +0000 | [diff] [blame] | 27 | // CHECK-UNSUPPORTED-NOT: "-Wno-microsoft" |
| 28 | // CHECK-UNSUPPORTED-NOT: "-Wmicrosoft" |
Chad Rosier | 8071797 | 2011-08-26 18:30:43 +0000 | [diff] [blame] | 29 | // CHECK-UNSUPPORTED-NOT: "-Wvla" |
| 30 | // CHECK-UNSUPPORTED-NOT: "-faltivec" |
| 31 | // CHECK-UNSUPPORTED-NOT: "-mthumb" |
| 32 | // CHECK-UNSUPPORTED-NOT: "-mlongcall" |
| 33 | // CHECK-UNSUPPORTED: "-mno-longcall" |
| 34 | // CHECK-UNSUPPORTED: "-msoft-float" |
| 35 | |
Sebastian Pop | 9ec60df | 2012-01-20 22:01:23 +0000 | [diff] [blame] | 36 | // RUN: %clang -target i386-apple-darwin10 \ |
Chad Rosier | 4fe4d73 | 2011-09-08 00:38:00 +0000 | [diff] [blame] | 37 | // RUN: -Wconstant-logical-operand -save-temps \ |
| 38 | // RUN: -fapple-kext -### -fsyntax-only %s 2> %t |
| 39 | // RUN: FileCheck --check-prefix=CHECK-UNSUPPORTED2 < %t %s |
| 40 | |
| 41 | // CHECK-UNSUPPORTED2: cc1plus" |
| 42 | // CHECK-UNSUPPORTED2-NOT: "-Wconstant-logical-operand" |
Bob Wilson | 6fb522e | 2012-04-04 07:06:30 +0000 | [diff] [blame] | 43 | |
Chad Rosier | 7ed4f66 | 2012-06-26 16:57:41 +0000 | [diff] [blame^] | 44 | // Check that -serialize-diagnostics does not cause an "argument unused" error. |
| 45 | // RUN: %clang -target i386-apple-darwin10 \ |
| 46 | // RUN: -Wall -fapple-kext -### -serialize-diagnostics %t.dia -c %s 2>&1 | \ |
| 47 | // RUN: FileCheck --check-prefix=CHECK-UNUSED %s |
| 48 | |
Bob Wilson | 6fb522e | 2012-04-04 07:06:30 +0000 | [diff] [blame] | 49 | // Check that --serialize-diagnostics does not cause an "argument unused" error. |
| 50 | // RUN: %clang -target i386-apple-darwin10 \ |
Bob Wilson | e1fde1d | 2012-04-04 14:43:40 +0000 | [diff] [blame] | 51 | // RUN: -Wall -fapple-kext -### --serialize-diagnostics %t.dia -c %s 2>&1 | \ |
Benjamin Kramer | c9aa9c0 | 2012-04-04 09:05:21 +0000 | [diff] [blame] | 52 | // RUN: FileCheck --check-prefix=CHECK-UNUSED %s |
| 53 | |
| 54 | // CHECK-UNUSED-NOT: argument unused |
| 55 | // CHECK-UNUSED: cc1plus |