[lworld] RFR: 8377714: [lworld] Re-enable virtual thread tests [v2]

Patricio Chilano Mateo pchilanomate at openjdk.org
Fri Feb 20 00:40:18 UTC 2026


On Wed, 18 Feb 2026 16:28:48 GMT, Marc Chevalier <mchevalier at openjdk.org> wrote:

>> Patricio Chilano Mateo has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains three commits:
>> 
>>  - Review comments
>>  - Merge branch 'lworld' into JDK-8377714
>>  - v1
>
> src/hotspot/share/runtime/continuationFreezeThaw.cpp line 2893:
> 
>> 2891:   // As a result, f.is_deoptimized_frame() is always false and we must test hf to know if the frame is deoptimized.
>> 2892:   frame f = new_stack_frame<ContinuationHelper::CompiledFrame>(hf, caller, is_bottom_frame, augmented ? fsize - hf.cb()->frame_size() : 0);
>> 2893:   assert((int)(caller.sp() - f.sp()) == (augmented ? fsize : f.cb()->frame_size()), "");
> 
> The expression `f.cb()->frame_size()` is not crashing only if `f` is compiled otherwise `f.cb() == nullptr`. But `f` seems to be a compiled frame (since `new_stack_frame<ContinuationHelper::CompiledFrame>`), so why `f.cb()->frame_size()` isn't always what we want?

Right, `f` is a compiled frame. So before this change, `caller.sp()` was always set to `f.sp() + f.cb()->frame_size()`, even when `f` was an extended frame. The reason for this is that we needed to keep a reference to the saved `rbp/rfp` in `f`, because we might needed to patch it later (we need to thaw the callee first before patching the caller's saved `rbp/rfp`). But now, the saved `rbp/rfp` is stored together with the saved return pc. So `caller.sp()` is set to point to `f`'s actual caller `sp`. The difference between `caller.sp()` and `f.sp()` should then be the real size of `f` (stored in `fsize` for extended frames).

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

PR Review Comment: https://git.openjdk.org/valhalla/pull/2085#discussion_r2830815120


More information about the valhalla-dev mailing list