benson@HARVARD.HARVARD.EDU (Benson I. Margulies Kendall Square Research Corp.) (03/17/89)
In gcc 1.34, the following compiles correctly (it seems) and without
error only so long as -O is not provided on the command line.
When -O is given, I get:
sasm.c: In function set_fpastatus:
sasm.c:5: inconsistent operand constraints in an `asm'
gcc: Program cc1 got fatal signal 4.
This is also a test case for the rejection of "asm volatile"
in -traditional mode.
void
set_fpastatus(value)
long value;
{
asm volatile ("ld %0,%%fsr" : : "m" (value));
}
long
get_fpastatus()
{
long ret;
asm ("st %%fsr,%0" : "=m" (ret));
return ret;
}
void
sparc_compare_single_floats(f1, f2)
float f1;
float f2;
{
asm volatile ("fcmps %0,%1" : : "f" (f1), "f" (f2));
}
void
sparc_compare_double_floats(f1, f2)
double f1;
double f2;
{
asm volatile ("fcmpd %0,%1" : : "f" (f1), "f" (f2));
}