RFR: Adapt upstream object pinning API

Aleksey Shipilev shade at redhat.com
Wed Apr 4 18:39:25 UTC 2018


On 04/04/2018 08:28 PM, Zhengyu Gu wrote:
>>>>> *) Since you are renaming the RT stubs, should you also rename the MacroAssembler entries? Does it
>>>>> do something special for arrays, or is it just the stub for the call to
>>>>> SharedRuntime::{pin|unpin}_object?
>>>>>
>>>>>     MacroAssembler::pin_critical_native_array
>>>>>     MacroAssembler::unpin_critical_native_array
>>>>
>>>> No. SharedRuntime::{pin|unpin}_object are generic. MacroAssembler::pin/unpin_critical_native_array
>>>> generate code to make RT calls for array arguments.
>>>
>>> Right. But is there anything special about MacroAssembler::pin/unpin_critical_native_array so that
>>> we need to call them *_array? If not, we should just call them pin/unpin_object, regardless where
>>> they are being called from. This would help to employ these stubs for future use cases.
>>
>> I see.
>>
>> However, this method is not that generic, it follows unpack_array_argument(), uses rax as
>> temporary register, and does not support all object sizes.
> 
> Nevermind of object size, I don't think we will see narrowOop here.
> 
> But I still do see a good way to make it generic, other usages might not need to save all those
> registers, and need stack slot to save the value, etc.

Ok, fine.

-Aleksey



More information about the shenandoah-dev mailing list