RFR (M): 8008918: Reference statistics events for the tracing framework

Thomas Schatzl thomas.schatzl at oracle.com
Wed Mar 6 19:49:17 UTC 2013


Hi,

On Wed, 2013-03-06 at 18:06 +0100, Erik Helin wrote:
> Hi Thomas,
>[..]
> If one refactor the code so that the ReferenceProcessor decides if the
> reference processing should run in parallel, then one has to ensure that
> the collector specific logic in the different branches still are
> correct.
> 
> This is a cleanup that we definitely should do, but I would like to see
> it done as a separate change to ease the reviewing.
> 

Okay.

> On 03/04/2013 09:24 AM, Thomas Schatzl wrote:
>  > I.e. what the change basically did is to replace the call to
>  > process_discovered_reference by above sequence of three statements.
> 
> I would say that the change made the code go from two to three lines.
> Before the code looked like:
> 
>    if (rp->processig_is_mt()) {
>      rp->process...
>    } else {
>      rp->process...
>    }
>    gc_tracer->report_gc_reference_processing(rp->collect_statistics());
> 
> After the change, the code looks like:
> 
>    ReferenceProcessorStats stats;
>    if (rp->processig_is_mt()) {
>      stats = rp->process...
>    } else {
>      stats = rp->process...
>    }
>    gc_tracer->report_gc_reference_processing(stats);
> 
> The only difference in terms of lines is the addition of the "stats" 
> variable.
> 
> In my opinion, this is a motivated cost for providing a more robust way 
> to collect the statistics from the reference processor. What do you think?
> 

Agree.

Note that I'm not an Openjdk reviewer, so you must find an additional
reviewer...

Thomas





More information about the hotspot-gc-dev mailing list