[jdk23] Integrated: 8333583: Crypto-XDH.generateSecret regression after JDK-8329538

2024-06-26 Thread Volodymyr Paprotski
On Tue, 25 Jun 2024 23:50:20 GMT, Volodymyr Paprotski wrote: > Hi all, > > This pull request contains a backport of commit > [f101e153](https://github.com/openjdk/jdk/commit/f101e153cee68750fcf1f12da10e29806875b522) > from the [openjdk/jdk](https://git.openjdk.org/jdk) repository. > > The com

Integrated: 8333583: Crypto-XDH.generateSecret regression after JDK-8329538

2024-06-25 Thread Volodymyr Paprotski
On Fri, 14 Jun 2024 20:23:04 GMT, Volodymyr Paprotski wrote: > This fix recovers XDH performance but removes some of the P256 gains > (~-8-14%). Still faster, but not as much. > > The fix is to undo 'int' return type on mult()/square(), which allowed to > return partially reduced result (e.g.