-
Enhancement
-
Resolution: Fixed
-
P3
-
5.0
-
b120
-
x86
-
windows_2000
Name: js151677 Date: 09/13/2004
A DESCRIPTION OF THE REQUEST :
64-bit CPUs like AMD Opteron can multiply two 64-bit integers and produce a 128-bit result. in Java there is currently no way to access this feature. VMs even have no way to offer this capability to an application, because there is no 128-bit type for returning the result.
JUSTIFICATION :
in the security area, asymmetric cryptography plays an important role. algorithms like RSA use long integer arithmentic extensively. for instance, certain baisc long integer operations like multiplication have quadratic running time. in this case, using a 64-bit multiplication as a basis instead of a 32-bit muliplication can decrease the number of required steps to a fourth. thus, time consuming RSA operations could be much faster just by exploiting 64-bit muliplication.
this feature could speed up the java.math.BigInteger class significantly.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
the most natural thing would be to introduce a 128-bit type; e.g. long128.
CUSTOMER SUBMITTED WORKAROUND :
use 32-bit multiplication with 64-bit results. however, using this takes four times longer in an algorithm with quadratic running time.
(Incident Review ID: 310503)
======================================================================
- relates to
-
JDK-8157527 Replace @since 1.9 with @since 9 on new math methods
-
- Resolved
-
-
JDK-8157502 make docs broken after JDK-5100935
-
- Closed
-
-
JDK-8157485 Improve 64-bit integer multiplication with Montgomery multiplication
-
- Open
-
-
JDK-8014320 Faster multiplication and division of very large integers
-
- Open
-
-
JDK-8187684 Intrinsify Math.multiplyHigh(long, long)
-
- Resolved
-
-
JDK-8188044 We need Math.unsignedMultiplyHigh
-
- Resolved
-
-
JDK-8188046 java.lang.Math.mutliplyHigh does not run in constant time
-
- Resolved
-
-
JDK-8182981 Need tests for missing coverage in java.lang.Math
-
- Closed
-
-
JDK-6535058 Inconvenient to detect overflow while multiplying two long values
-
- Closed
-