The problem happens if post_early_vm_start is triggered. The fix is to complete initialization once threadObj become available.
I'vent observed that recompute_enable and hitting assertion might happens before this step. However it might be makes sense to check state in assertion if needed. ------------- Commit messages: - fixed comments after feedback, some polishing - 8362203: assert(state == nullptr || state->get_thread_oop() != nullptr) failed: incomplete state Changes: https://git.openjdk.org/jdk/pull/26303/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=26303&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8362203 Stats: 19 lines in 4 files changed: 17 ins; 1 del; 1 mod Patch: https://git.openjdk.org/jdk/pull/26303.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/26303/head:pull/26303 PR: https://git.openjdk.org/jdk/pull/26303