[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Floating point problems



Hi!

What's wrong with the following program?

main() {
	double x = 1.0;
	x *= 1e-310;
}

This results in a floating point exception on my Ruffian (for values
somwhere between 1e-300 and 1e-325, independent of kernel and compiler),
but not on any intel. The assembler output seems to indicate that the
two values are just loaded into registers and multiplied.
What is going on?

MfG, Ulrich

--
"If you were a boy I'd say are you going to seek your fortune?" "Can't girls
seek their fortune?" "I think they're supposed to seek a boy with a fortune."
                                               T. Pratchett, "Equal Rites"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []