On Fri, 19 Jun 2026 08:05:16 GMT, Alan Bateman <[email protected]> wrote:

>> Jaikiran Pai has updated the pull request incrementally with one additional 
>> commit since the last revision:
>> 
>>   no need for ResourceMark
>
> src/hotspot/share/runtime/synchronizer.cpp line 323:
> 
>> 321:   if ((obj)->mark().is_inline_type()) {  \
>> 322:     JavaThread* THREAD = current;           \
>> 323:     ResourceMark rm(THREAD);                \
> 
> Is the RM still needed?

I wasn't aware what a `ResourceMark` is. Reading the code and the code comment 
on `ResourceMarkImpl`, I believe it was here for tracking the resource 
allocated in the implementation of `obj->klass()->external_name()` (please 
correct me if I'm wrong). With that now gone, I think the `ResourceMark` is no 
longer needed. I've updated the PR accordingly.

I have triggered tier testing to be sure that this doesn't cause any issues.

-------------

PR Review Comment: 
https://git.openjdk.org/valhalla/pull/2568#discussion_r3442290635

Reply via email to