Subject: Re: Floating Point Exceptions in Povray
To: Henry R. Bent <>
From: None <>
List: port-vax
Date: 11/03/2002 19:49:41
On Sun, 3 Nov 2002, Henry R. Bent wrote:

> Hi all,
> Since the subject of floating-point math has arisen I figure I'll see if the
> list has any brilliant ideas for my problem.
> This is with Povray 3.1g on a 4k/90 using the standard "skyvase.pov" file for
> the benchmark at  All my compiles of povray
> get to rendering line 99 in the file and then coredump with a floating point
> exception.  Running gdb on the coredump claims only this:
> (gdb) bt
> #0  0x1bff4 in do_phong (Cannot access memory at address 0x7fffd234.
> do_phong is a lighting function, and the only floating point calculation that it
> contains is:
> x = fabs(acos(NdotL)) / M_PI_2
> where x and NdotL are doubles and M_PI_2 is the constant (PI) / 2.

whats the value of NdotL when it dies?  I'd guess >1.0 or <-1.0.