commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "aeriform (JIRA)" <>
Subject [jira] Commented: (MATH-82) [math] FractionFormatTest doesn't compile under JDK 1.3
Date Fri, 27 Oct 2006 07:54:17 GMT
    [ ] 
aeriform commented on MATH-82:

Not a bug according to Sun.

"We are aware of the issue raised by this bug; it is the same issue
raised in 4807358, the "almabench" bug.  Both this bug and 4807358 are
symptoms of the same problem: the sin/cos routines in the client
compiler under 1.3.1 did *not* comply with the Math.{sin/cos}
specification.  As explained below, the way they did not comply could
be the source of a large amount of error.  As a consequence of fixing
this compliance problem (bug 4345903), the x86 sin/cos routines in 1.4
and later are slower than in 1.3.1 client.

The x87 FPU has fsin and fcos instructions to accelerate the
computation of sine and cosine.  However, these instructions have a
number of limitations. First, they only return sensible results over a
limited range of values, +/- 2^63.  Java's sin/cos functions are defined
over the full double range, roughly +/- 2^1023.  Second, even within
the +/-2^63 range, nearly all fsin/fcos implementations perform faulty
*argument reduction,* consequently, the results can be very wrong
outside of a narrow range of +/- pi/4.


> [math]  FractionFormatTest doesn't compile under JDK 1.3
> --------------------------------------------------------
>                 Key: MATH-82
>                 URL:
>             Project: Commons Math
>          Issue Type: Bug
>    Affects Versions: Nightly Builds
>         Environment: Operating System: All
> Platform: All
>            Reporter: Niall Pemberton
>            Priority: Minor
>         Attachments: math_FractionFormatTest_JDK13.patch, TEST-org.apache.commons.math.complex.ComplexUtilsTest.txt
> FractionFormatTest uses NumberFormat.getIntegerInstance() which is a JDK 1.4 
> method. Changing this to use getInstance() instead and then using 
> setParseIntegerOnly(true) allows it to compile under JDK 1.3 - and the test 
> runs and passes.
> Its probably a moot point though since ComplexUtilsTest fails using JDK 
> 1.3.1_04 (on both W2K and Windows XP).

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message