RFR: 8139200: Eliminate G1ParClosureSuper::_worker_id
Thomas Schatzl
thomas.schatzl at oracle.com
Thu Oct 15 09:05:04 UTC 2015
Hi Kim,
On Tue, 2015-10-13 at 15:02 -0400, Kim Barrett wrote:
> On Oct 9, 2015, at 3:26 AM, Kim Barrett <kim.barrett at oracle.com> wrote:
> >
> > Please review this cleanup of the construction of G1ParClosureSuper
> > and classes derived from it.
> >
> > We move the _worker_id member from G1ParClosureSuper down to
> > G1ParCopyHelper, where it is actually used. Other subclasses of
> > G1ParClosureSuper no longer need to worry about it. In particular,
> > the complicated initialization of G1ParScanClosure is eliminated,
> > getting rid of G1ParClosureSuper::set_par_scan_thread_state.
> >
> > [In G1ParCopyHelper we could obtain the worker_id from the
> > par_scan_state, but that would add a memory indirection in code that
> > is performance sensitive.]
[...]
> > Testing:
> > JPRT
>
> It turns out the webrev.00 I posted wasn’t actually the intended final version, and
> contains a mistake that prevents it from even building. Here’s the corrected webrev
> and the incremental change:
>
> http://cr.openjdk.java.net/~kbarrett/8139200/webrev.01/
> http://cr.openjdk.java.net/~kbarrett/8139200/webrev.01.incr/
>
> The difference is that G1ParCopyHelper::_worker_id needs to be protected, not private.
>
> Sorry for the mixup.
>
One comment for the comment for G1ParCopyHelper::_worker_id: please
start the comment with upper case and end it with a full stop. ;)
I do not need a new review for that change.
Looks good.
Thomas
More information about the hotspot-gc-dev
mailing list