RFR(L): JDK-8046936 : JEP 270: Reserved Stack Areas for Critical Sections

Karen Kinnear karen.kinnear at oracle.com
Fri Nov 20 17:38:09 UTC 2015


One other example is an unlock that requires three steps - update state, update owner and
unpark successor.

thanks,
Karen

> On Nov 19, 2015, at 9:25 PM, David Holmes <david.holmes at oracle.com> wrote:
> 
> On 20/11/2015 4:10 AM, Doug Lea wrote:
>> On 11/16/2015 08:00 PM, David Holmes wrote:
>>>> I've tried that :-) The amount of code being executed with
>>>> the ReservedStackAccess privilege tends to increase very
>>>> quickly and I was concerned about keeping the size of the
>>>> reserved area small.
>>> 
>>> How much space does each level of calling need? I know that is hard to
>>> answer
>>> but are we talking a few bytes, few kb, many kb?
>>> 
>> 
>> Relatedly, could someone spell out in more detail the
>> worst-case behavior of StackOverflowError? Knowing this
>> might be helpful in some cases in which we might be able to
>> at least preserve minimal sanity without needing to reserve.
> 
> Not sure what you are asking for Doug - worst-case is that an action that is critical to complete does not complete. Best example is lock/unlock which have to both update AQS-state and update owner. If only one is done the lock internal state is inconsistent and the lock ceases to function.
> 
> David
> 
>> -Doug
>> 
>> 
>> 




More information about the core-libs-dev mailing list