Mail Archives: djgpp/1997/06/15/23:42:20
> Hello. There are ample resources on the web for inline assembly in
> DJGPP, but very little regarding floating point. I was wondering:
> what are the FPU registers named? st(0),st(1),... or something else?
The compiler can be a great aid at figuring things like this out.
Try the following
test.c
double f(double x)
{
return x+2.54*x;
}
Compile it with the following command line
gcc -S -o - test.c
Now look at what is displayed on screen. You should see references to
fstp %st(0)
fmulp %st,%st(1)
HTH
Andrew
- Raw text -