2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / gcc.c-torture / compile / 20001205-1.c
blob4a917a2e2d79b093d95bfed46196d6d71d1e13ed
1 /* This does not work on m68hc11 due to the asm statement which forces
2 two 'long' (32-bits) variables to go in registers. */
3 /* { dg-do assemble { xfail m6811-*-* m6812-*-* } } */
5 static inline unsigned long rdfpcr(void)
7 unsigned long tmp, ret;
8 __asm__ ("" : "=r"(tmp), "=r"(ret));
9 return ret;
12 static inline unsigned long
13 swcr_update_status(unsigned long swcr, unsigned long fpcr)
15 swcr &= ~0x7e0000ul;
16 swcr |= (fpcr >> 3) & 0x7e0000ul;
17 return swcr;
20 unsigned long osf_getsysinfo(unsigned long flags)
22 unsigned long w;
23 w = swcr_update_status(flags, rdfpcr());
24 return w;