RFR: 8327147: optimized implementation of round operation for x86_64 CPUs [v2]

Srinivas Vamsi Parasa duke at openjdk.org
Tue Mar 5 00:08:05 UTC 2024


> The goal of this PR is to provide ~4x faster implementation of Math.ceil, Math.floor and Math.rint for x86_64 CPUs.
> 
> Below is the performance data on an Intel Tiger Lake machine. 
> 
> <html xmlns:v="urn:schemas-microsoft-com:vml"
> xmlns:o="urn:schemas-microsoft-com:office:office"
> xmlns:x="urn:schemas-microsoft-com:office:excel"
> xmlns="http://www.w3.org/TR/REC-html40">
> 
> <head>
> 
> <meta name=ProgId content=Excel.Sheet>
> <meta name=Generator content="Microsoft Excel 15">
> <link id=Main-File rel=Main-File
> href="file:///C:/Users/sparasa/AppData/Local/Temp/msohtmlclip1/01/clip.htm">
> <link rel=File-List
> href="file:///C:/Users/sparasa/AppData/Local/Temp/msohtmlclip1/01/clip_filelist.xml">
> 
> 
> </head>
> 
> <body link="#0563C1" vlink="#954F72">
> 
> 
> Benchmark | Stock JDK   (ops/ms) | This PR (ops/ms) | Speedup
> -- | -- | -- | --
> MathBench.ceilDouble | 547979 | 2170198 | 3.96
> MathBench.floorDouble | 547979 | 2167459 | 3.96
> MathBench.rintDouble | 547962 | 2130499 | 3.89
> 
> 
> 
> </body>
> 
> </html>

Srinivas Vamsi Parasa has updated the pull request incrementally with one additional commit since the last revision:

  unify the implementation

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/18089/files
  - new: https://git.openjdk.org/jdk/pull/18089/files/e8e3b9db..0401e18e

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=18089&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=18089&range=00-01

  Stats: 26 lines in 2 files changed: 0 ins; 25 del; 1 mod
  Patch: https://git.openjdk.org/jdk/pull/18089.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/18089/head:pull/18089

PR: https://git.openjdk.org/jdk/pull/18089


More information about the hotspot-compiler-dev mailing list