OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [asm-wide-1.c] - Blame information for rev 298

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 298 jeremybenn
/* Wide string literals should not be allowed in asm.  */
2
/* Origin: Joseph Myers <joseph@codesourcery.com> */
3
/* { dg-do compile } */
4
/* { dg-options "" } */
5
 
6
int foo asm (L"bar"); /* { dg-error "14:wide string literal in 'asm'" } */
7
 
8
asm (L"foo"); /* { dg-error "6:wide string literal in 'asm'" } */
9
 
10
void
11
f (void)
12
{
13
  int x = 1;
14
  asm (L"foo"); /* { dg-error "8:wide string literal in 'asm'" } */
15
  asm ("foo" :
16
       L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */
17
  asm ("foo" : [x]
18
       L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */
19
  asm ("foo" : [x] "=g" (x),
20
       L"=g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */
21
  asm ("foo" : :
22
       L"g" (x)); /* { dg-error "8:wide string literal in 'asm'" } */
23
  asm ("foo" : : :
24
       L"memory"); /* { dg-error "8:wide string literal in 'asm'" } */
25
  asm ("foo" : : : "memory",
26
       L"memory"); /* { dg-error "8:wide string literal in 'asm'" } */
27
}
28
 
29
/* Extra errors from the substitution of "" for wide strings: */
30
/* { dg-error "output" "output" { target *-*-* } 16 } */
31
/* { dg-error "output" "output" { target *-*-* } 18 } */
32
/* { dg-error "output" "output" { target *-*-* } 20 } */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.