diff options
Diffstat (limited to 'test/CodeGen/asm.c')
-rw-r--r-- | test/CodeGen/asm.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/test/CodeGen/asm.c b/test/CodeGen/asm.c index d7309149eb..8aa392aa80 100644 --- a/test/CodeGen/asm.c +++ b/test/CodeGen/asm.c @@ -69,11 +69,22 @@ unsigned char t12(unsigned input) { return output; } +unsigned char t13(unsigned input) { + unsigned char output; + __asm__("xyz %1" + : "=a" (output) + : "0" (input)); + return output; +} + +// bitfield destination of an asm. struct S { int a : 4; }; -void test13(struct S *P) { +void t14(struct S *P) { __asm__("abc %0" : "=r"(P->a) ); } + + |