diff options
author | John McCall <rjmccall@apple.com> | 2011-05-10 23:39:47 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-05-10 23:39:47 +0000 |
commit | dfbf9341adc350019740750573ba02185a978c60 (patch) | |
tree | 69c82dcdfea5e0a0cd23afbf2c58f50de22cb160 /clang/test/Sema/asm.c | |
parent | 14e1b58405a064aa8d9576eab43b59bae0ceced3 (diff) | |
download | bcm5719-llvm-dfbf9341adc350019740750573ba02185a978c60.tar.gz bcm5719-llvm-dfbf9341adc350019740750573ba02185a978c60.zip |
Use a heralded conversion to bool in inline-asm constraints.
llvm-svn: 131170
Diffstat (limited to 'clang/test/Sema/asm.c')
-rw-r--r-- | clang/test/Sema/asm.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/clang/test/Sema/asm.c b/clang/test/Sema/asm.c index 7f0f396b9d8..d8161c819b9 100644 --- a/clang/test/Sema/asm.c +++ b/clang/test/Sema/asm.c @@ -105,3 +105,11 @@ void test10(void){ register int r asm ("cx"); register int rr asm ("rr_asm"); // expected-error{{unknown register name 'rr_asm' in asm}} } + +// This is just an assert because of the boolean conversion. +// Feel free to change the assembly to something sensible if it causes a problem. +// rdar://problem/9414925 +void test11(void) { + _Bool b; + asm volatile ("movb %%gs:%P2,%b0" : "=q"(b) : "0"(0), "i"(5L)); +} |