RFR: 8330253: Skip verify_consistent_lock_order when deoptimizing from monitorenter bytecode. [v3]

Daniel D. Daugherty dcubed at openjdk.org
Thu Apr 18 15:01:05 UTC 2024


On Thu, 18 Apr 2024 05:31:55 GMT, Axel Boldt-Christmas <aboldtch at openjdk.org> wrote:

>> src/hotspot/share/runtime/deoptimization.cpp line 443:
>> 
>>> 441:   }
>>> 442: #ifdef ASSERT
>>> 443:   if (LockingMode == LM_LIGHTWEIGHT && !realloc_failures) {
>> 
>> In the new code, you are no longer account for `realloc_failures` being true.
>> I'm not convinced that is okay here.
>
> Originally I had those conditions in as well (to make it more clear and explicit). But Vladimir thought them superfluous. They are implicitly true from `lock_order.is_nonempty() -> LockingMode == LM_LIGHTWEIGHT && !realloc_failures` because we only ever add elements to `lock_order` if `LockingMode == LM_LIGHTWEIGHT && !realloc_failures` is true.

Thanks for the clarification.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18782#discussion_r1570927939


More information about the hotspot-dev mailing list