Subject: Floating Point Exceptions in Povray
To: None <port-vax@netbsd.org>
From: Henry R. Bent <hbent@cs.oberlin.edu>
List: port-vax
Date: 11/03/2002 17:56:56
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 http://www.haveland.org/povbench. 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.
I tried statically linking the executable (which made the atan example work
before) but that was no help. Compiling with -mg slows the program down a LOT
(why? doesn't the 4k/90 have hardware G support?) and doesn't help either. Does
anyone have any ideas out there? Obviously this isn't a life or death situation
but I'd love to know what's going on here.
--
Henry Bent
hbent@cs.oberlin.edu