2011-06-04 06:24:54 +08:00
|
|
|
// REQUIRES: x86-registered-target
|
2011-07-10 01:41:47 +08:00
|
|
|
|
2016-03-11 06:40:02 +08:00
|
|
|
// RUN: not %clang_cc1 -triple i386-apple-darwin10 -emit-obj %s -o /dev/null > %t 2>&1
|
|
|
|
// RUN: FileCheck %s < %t
|
2016-04-07 03:58:07 +08:00
|
|
|
// RUN: not %clang -target i386-apple-darwin10 -fembed-bitcode -c %s -o /dev/null 2>&1 | \
|
2015-02-12 10:06:55 +08:00
|
|
|
// RUN: FileCheck --check-prefix=CRASH-REPORT %s
|
|
|
|
// CRASH-REPORT: <inline asm>:
|
|
|
|
// CRASH-REPORT: error: invalid instruction mnemonic 'abc'
|
2016-04-07 03:58:07 +08:00
|
|
|
// CRASH-REPORT: error: cannot compile inline asm
|
2015-02-12 10:06:55 +08:00
|
|
|
// CRASH-REPORT-NOT: note: diagnostic msg:
|
2010-04-07 02:46:25 +08:00
|
|
|
|
|
|
|
int test1(int X) {
|
2010-09-07 06:09:27 +08:00
|
|
|
// CHECK: error: invalid instruction mnemonic 'abc'
|
2010-04-07 02:46:25 +08:00
|
|
|
__asm__ ("abc incl %0" : "+r" (X));
|
|
|
|
return X;
|
|
|
|
}
|