RFR: 8254108: ciReplay: Support incremental inlining [v3]
Christian Hagedorn
chagedorn at openjdk.java.net
Thu Nov 18 10:33:34 UTC 2021
On Wed, 17 Nov 2021 20:41:10 GMT, Dean Long <dlong at openjdk.org> wrote:
>> I've added a comment to make it more clear. So, this code is only to record the late inlining decision to later dump it to the replay file. I think initializing `should_delay = AlwaysIncrementalInline` is a good idea. `should_delay` can only become true but not false anymore during normal compilation.
>>
>> But I think we need to leave `|| AlwaysIncrementalInline` in here https://github.com/openjdk/jdk/blob/master/src/hotspot/share/opto/doCall.cpp#L192 in case someone wants to replay compile with that flag even though the replay file recorded a different late inlining decision.
>>
>> I also fixed the test if run with `-XX:+AlwaysIncrementalInline`.
>
> Shouldn't the recorded inlining decision always override flags like -XX:+AlwaysIncrementalInline?
> This brings up the question of how to handle flags. If we stored them in the replay file, then the replay compile could compare those to the current flags and if they don't match:
> 1) give a warning and continue, correct replay not guaranteed
> 2) give an error and refuse to continue
> 3) override current flags with saved flags (this could be implemented by having the "ci" layer cache flags settings for each compile)
As we have discussed offline, it's best not to treat `AlwaysIncrementalInline` specially given that we are already enforcing the general inlining decisions based on the replay data. I will therefore remove ` || AlwaysIncrementalInline` from L192.
About the flag handling in general, as you have suggested offline, I also think it's a good option to put the used flags in the replay file in the future and enforce them. If the user wants to run a different set of flags for any reasons then the replay file can be adapted accordingly.
-------------
PR: https://git.openjdk.java.net/jdk/pull/6413
More information about the hotspot-compiler-dev
mailing list