8350488: [leyden] Experimental AOT-only mode#44
Conversation
|
👋 Welcome back shade! A progress list of the required criteria for merging this PR into |
|
@shipilev This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 107 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@vnkozlov) but any other Committer may sponsor as well. ➡️ To flag this PR as ready for integration with the above commit message, type |
|
Sample performance results, after pre-training In both cases, "user" time goes down because we have no additional code load / JIT compilations. In 32-core case, we can see that peak performance suffers a bit, since preload code is not 100% efficient. The combination of these two factors is a net benefit in 2-core case: not doing JIT compilations more than pays for preload code inefficiency. This tradeoff of course depends on how well-trained the scenario is.
|
|
Plus, preload code needs to be a bit more resilient to invalidations, which would improve the perf gap here: #38. With that POC patch applied, the peak performance gap shortens considerably: |
vnkozlov
left a comment
There was a problem hiding this comment.
Looks good. Next step could be to cache only preload code during training to reduce size of cached data and time to load it. You don't need to save profiling data too.
Yes, that would a good next step if we find this thing useful. Thanks for the review! /integrate |
|
/sponsor |
|
Going to push as commit aa4e947.
Your commit was automatically rebased without conflicts. |
|
Proposed solution looks to me way too specific and niche. Instead, I'd prefer to see a way to combine different JIT-compilation modes ( |
There are interesting use cases where we want the AOT-only mode. We can emulate this in current Leyden prototype by relying on preload code, and stopping any profiling, which would naturally lead to no JIT compilations. This would also make interpreter code a bit faster in case we need to fall back there. This mode looks also helpful for studying the compiler dynamics.
Additional testing:
-XX:+PreloadOnlyruntime/cdsruntime/cdswith-XX:+PreloadOnlyProgress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/leyden.git pull/44/head:pull/44$ git checkout pull/44Update a local copy of the PR:
$ git checkout pull/44$ git pull https://git.openjdk.org/leyden.git pull/44/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 44View PR using the GUI difftool:
$ git pr show -t 44Using diff file
Download this PR as a diff file:
https://git.openjdk.org/leyden/pull/44.diff
Using Webrev
Link to Webrev Comment