RFR: 8334755: Asymptotically faster implementation of square root algorithm [v45]

Raffaello Giulietti rgiulietti at openjdk.org
Sat Jul 27 20:56:37 UTC 2024


On Sat, 27 Jul 2024 14:44:15 GMT, fabioromano1 <duke at openjdk.org> wrote:

>> I have implemented the Zimmermann's square root algorithm, available in works [here](https://inria.hal.science/inria-00072854/en/) and [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root).
>> 
>> The algorithm is proved to be asymptotically faster than the Newton's Method, even for small numbers. To get an idea of how much the Newton's Method is slow,  consult my article [here](https://arxiv.org/abs/2406.07751), in which I compare Newton's Method with a version of classical square root algorithm that I implemented. After implementing Zimmermann's algorithm, it turns out that it is faster than my algorithm even for small numbers.
>
> fabioromano1 has updated the pull request incrementally with two additional commits since the last revision:
> 
>  - Correct test method name
>  - Updated sqrt speed test benchmark

At the end of the day the existing method should be removed, as it serves no purpose.
But I'll comment further on `MBI.java` next week.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/19710#issuecomment-2254251900


More information about the core-libs-dev mailing list