Integrated: 8344014: Simplify TracePhase constructor

Thomas Stuefe stuefe at openjdk.org
Wed Nov 13 12:32:41 UTC 2024


On Tue, 12 Nov 2024 07:56:24 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

> As a prerequisite for [JDK-8344009](https://bugs.openjdk.org/browse/JDK-8344009), `TracePhase` constructor needs to know the PhaseTraceId. And while we are at it, it can be simplified: trace strings can be kept in via x-macro with the IDs, and it is sufficient to pass in the IDs, no need to pass the pointer to the counters since we use the same counters anyway.
> 
> Since this is a somewhat invasive but purely mechanical change, I separate this work from [JDK-8344009](https://bugs.openjdk.org/browse/JDK-8344009).
> 
> There are no functional changes. Trace texts have been faithfully taken over, even in the case where the original TracePhase constructor invocation got fed an empty string (`_t_vector` and `_t_renumberLive`) - whether this was intentional or not, this patch does not change it.
> 
> The patch preserves the possibility to override the phase name with an explicit argument to the constructor. This is used in one existing case ("computeLive (sbplr)"), again, to faithfully preserve the log format.
> 
> Test: I checked manually with +CITimeVerbose with and without patch and compared the output; output format is preserved.

This pull request has now been integrated.

Changeset: 133f8f31
Author:    Thomas Stuefe <stuefe at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/133f8f318675d5825defc8587911b53ecb9a7136
Stats:     199 lines in 18 files changed: 75 ins; 53 del; 71 mod

8344014: Simplify TracePhase constructor

Reviewed-by: dlong, roland

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

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


More information about the hotspot-compiler-dev mailing list