Mandy asked for some additional comments to make life easier for future readers. I've also stopped pretending the description for waitForReferenceProcessing is javadoc, since this function is private and only accessible via SharedSecrets or reflection that avoids access control.
Changes only in the jdk tree: New webrevs: full: http://cr.openjdk.java.net/~kbarrett/8156500/jdk.05/ incr: http://cr.openjdk.java.net/~kbarrett/8156500/jdk.05.inc/ Unchanged hotspot webrevs: full: http://cr.openjdk.java.net/~kbarrett/8156500/hotspot.04/ incr: http://cr.openjdk.java.net/~kbarrett/8156500/hotspot.04.inc/