Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/asm-wide-1.c @ 118:fd00160c1b76
ifdef TARGET_64BIT
author | mir3636 |
---|---|
date | Tue, 27 Feb 2018 15:01:35 +0900 |
parents | 04ced10e8804 |
children | 1830386684a0 |
line wrap: on
line source
/* Wide string literals should not be allowed in asm. */ /* Origin: Joseph Myers <joseph@codesourcery.com> */ /* { dg-do compile } */ /* { dg-options "" } */ int foo asm (L"bar"); /* { dg-error "14:wide string literal in 'asm'" } */ asm (L"foo"); /* { dg-error "6:wide string literal in 'asm'" } */ void f (void) { int x = 1; asm (L"foo"); /* { dg-error "8:wide string literal in 'asm'" } */ asm ("foo" : L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */ /* Extra errors from the substitution of "" for wide strings: */ /* { dg-error "output" "output" { target *-*-* } .-2 } */ asm ("foo" : [x] L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */ /* { dg-error "output" "output" { target *-*-* } .-1 } */ asm ("foo" : [x] "=g" (x), L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */ /* { dg-error "output" "output" { target *-*-* } .-1 } */ asm ("foo" : : L"g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */ asm ("foo" : : : L"memory"); /* { dg-error "8:wide string literal in 'asm'" } */ asm ("foo" : : : "memory", L"memory"); /* { dg-error "8:wide string literal in 'asm'" } */ }