In particular on Solaris we have a problem. The NMT _query_lock is created during VM argument parsing, which is after os::init(), but on Solaris os::solaris::synchronization_init() is called from os::init_2() which is after argument parsing - because sync init on Solaris depends on the arguments: UseLWPSynchronization and UsePthreads.
An assert needs to be added to ensure we don't accidentally initialize other instances too early.
- relates to
-
JDK-8213137 Remove static initialization of monitor/mutex instances
-
- Resolved
-