RFR: 8079082: VerifyNoCSetOopsClosure is derived twice from Closure

Mikael Gerdin mikael.gerdin at oracle.com
Mon Jul 27 12:25:36 UTC 2015


Hi Kim,

On 2015-07-24 22:41, Kim Barrett wrote:
> Please review this cleanup to eliminate improper and unnecessary
> multiple inheritance by a verification closure.
>
> - Changed the closure to an ordinary function object, with some
> simplifications, elimination of virtual functions, and renaming as a
> result.

Nice.

>
> - Eliminated VerifyNoCSetOopsPhase enum, instead just making the calls
> to setup the checking function pass in the appropriate string.  The
> only thing the enum values were used for was to determine the desired
> string.
>
> - Replaced CMMarkStack::oops_do with iterate function template.
>
> - Replaced GenericTaskQueue::oops_do with iterate function template.
> This class really has no business having a hard-wired iterator over
> oop elements.

It appears that you've adapted the assertion is_oop_or_null to an is_oop 
check in the function object.
I believe that the assertion that all oops on the global CM stack should 
pass the is_oop check but I guess we will find out if that's untrue :)



>
> - While I was in the neighborhood, eliminated an unnecessary nearby
> cast.
>
> CR:
> https://bugs.openjdk.java.net/browse/JDK-8079082
>
> Webrev:
> http://cr.openjdk.java.net/~kbarrett/8079082/webrev.00/

Looks good to me.
/Mikael

>
> Testing:
> jprt, local jtreg
>


More information about the hotspot-gc-dev mailing list