Request for review (XS): JDK-8006758: LinkResolver assertion (caused by @Contended changes)

David Holmes david.holmes at oracle.com
Thu Jan 24 01:33:19 PST 2013


Hi Aleksey,

On 24/01/2013 7:03 PM, Aleksey Shipilev wrote:
> Hi David,
>
> On 01/24/2013 12:53 PM, David Holmes wrote:
>> Based on your description this patch seems to address the immediate
>> problem.
>
> I think it is intrinsically valid given the "sun.misc.* booby trap
> everything" policy is being enforced.
>
>> My concern is whether this whole "privileged" notion that @Contended
>> introduced is actually valid? Is this how the constraint that @Contended
>> can only be applied to classes on the bootclasspath was implemented?
>
> This was discussed a numerous times at this list, e.g. here:
>   http://mail.openjdk.java.net/pipermail/hotspot-dev/2012-December/007502.html
>
> The current consensus is that sun.misc.* members should be
> unaccessible/noop-ed for unprivileged classes. This applies as the
> general rule, and some annotations can have the exception with the VM
> flag (-XX:-RestrictContended in this case).

It's not the policy I was questioning but the implementation. Given all 
the different notions of "privilege" that already exist this seems 
somewhat adhoc and slightly crude. But that is with hindsight.

David

> -Aleksey.
>


More information about the hotspot-dev mailing list