RFR: 8352042: [leyden] Parallel precompilation
Aleksey Shipilev
shade at openjdk.org
Fri Mar 14 12:27:02 UTC 2025
On Fri, 14 Mar 2025 12:22:00 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:
> For simplicity reasons, our current precompilation code uses effectively single-threaded blocking compiles. Even for simple cases, this makes assembly phase remarkably long. This does not scale well. We need to do precompilations in parallel.
>
> Unfortunately, I haven't found a good way to check that all async compilations are completed, so I introduced a new one.
>
> Additional testing:
> - [x] Ad-hoc precompilation tests
> - [x] Linux x86_64 server fastdebug, `runtime/cds`
$ ./run-leyden.sh
# Before
Generated source code for 10001 classes and compiled them in 19221 ms
AOTConfiguration recorded: app.aotconf
real 0m20.195s
user 0m51.408s
sys 0m1.466s
Reading AOTConfiguration app.aotconf and writing AOTCache app.aot
AOTCache creation is complete: app.aot
real 0m25.396s ; <--- no parallelism
user 0m25.212s
sys 0m0.696s
# After
Generated source code for 10001 classes and compiled them in 19320 ms
AOTConfiguration recorded: app.aotconf
real 0m20.228s
user 0m50.004s
sys 0m1.419s
Reading AOTConfiguration app.aotconf and writing AOTCache app.aot
AOTCache creation is complete: app.aot
real 0m3.672s ; <--- 6.6x parallelism
user 0m24.634s
sys 0m0.715s
-------------
PR Comment: https://git.openjdk.org/leyden/pull/49#issuecomment-2724524224
More information about the leyden-dev
mailing list