Christos Zoulas christos at
Thu Mar 26 18:34:55 UTC 2009

On Mar 26, 11:01am, Thomas.Rodriguez at Sun.COM (Tom Rodriguez) wrote:
-- Subject: Re: SIGFPE with FPE_FLTRES

| > I would just remove the trancendental c implementation. It is not  
| > consistent
| > with the java one anyway on amd64:
| You've got that backwards.  The C implementation is actually the  
| correct result as far as the spec goes and it's what is used by  
| StrictMath.log.  Math.log is allowed to produce less strict results  
| but it's always correct to use the same implementation as  
| StrictMath.log.
| >
| >
| >
| >
| > It's been 2 years that this is has been open. I don't understand how  
| > come
| > nobody else has hit this. My only guess is that people don't compare  
| > results
| > from successive runs.
| This is actually a bug in hotspot.  The interpreter is using the C  
| implementation and compiled code is using the log instructions on x86  
| but the interpreter and compiler are required to use the same  
| implementation so that Math.log is self consistent.  The amd64  
| interpreter has the code to use the x86 instruction but some code in  
| AbstractInterpreterGenerator::generate_method_entry keep it from  
| getting used.  Anyway, I've refiled this into hotspot and it should be  
| fixed in an upcoming hotspot.

Thanks a lot for explanation!


More information about the core-libs-dev mailing list