Mail Archives: djgpp/1997/09/22/20:45:45
Nate Eldredge (eldredge AT ap DOT net) wrote:
: At 09:06 9/20/1997 GMT, Nicholas Law wrote:
: >Hi all!
: >
: >What does a floating point exception actually mean? I keep getting it in my
: >3D rotation code. Is it something to do with the cos and sin functions, or
: >am I dividing by zero or something?
: Could be any of the above. The SIGFPE indicates some sort of math error
: reported by the coprocessor, and also integer division by zero. Math errors
: can include using NaN's, dividing by zero, logs and roots of negative
: numbers, and probably several other things. Try compiling with -g and using
: symify on the traceback you get when the error happens. This should help you
: find it.
I'm also getting SIGFPE in some code I wrote. I located the instruction
which causes it. It is a division with a number which is not a ZERO! And
when I turn off FPE exceptions code works giving the right results. Can
someone explain this?
P.S. I also tried reseting the FPU before that instruction. The result was
that SIGFPE disapeared!
--
// E-mail: smikecin AT bigfoot DOT com
// URL: http://fly.cc.fer.hr/~sime
- Raw text -