RFR: 8231672: Simplify the reference processing parallelization framework [v4]

Kim Barrett kbarrett at openjdk.java.net
Thu Mar 25 07:39:41 UTC 2021


On Tue, 23 Mar 2021 13:42:42 GMT, Leo Korinth <lkorinth at openjdk.org> wrote:

>> src/hotspot/share/gc/shared/referenceProcessor.hpp line 590:
>> 
>>> 588: enum class ThreadModel {Multi, Single};
>>> 589: 
>>> 590: class AbstractClosureContext {
>> 
>> This seems like an overly general name. This is related to reference
>> processing I think (not going to be used elsewhere), so I think should be
>> named accordingly.  ClosureContext also seems odd.  Maybe something
>> like AbstractRefProcOperations?  Handlers (slight bleh)?
>
> This is not the current name. This was updated to AbstractRefProcClosureContext earlier. I will update to AbstractRefProcOperations if you prefer that. I think your suggestion is better.

I like the Operations suffix better too.

>> src/hotspot/share/gc/shared/referenceProcessor.hpp line 596:
>> 
>>> 594:   virtual VoidClosure* complete_gc(uint worker_id) = 0;
>>> 595:   virtual void prepare_run_task(uint queue_count, ThreadModel tm, bool marks_oops_alive) = 0;
>>> 596:   uint index(uint id, ThreadModel tm) { return (tm==ThreadModel::Single)?0:id; }
>> 
>> I'd like more spaces around operators and punctuation in that value expression.
>
> The code was updated because Thomas also found it, are you okay with the current code?

Yes, updated code is fine.

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

PR: https://git.openjdk.java.net/jdk/pull/2782



More information about the hotspot-gc-dev mailing list