Skip to main content
PreparationZone Logo
PreparationZone
Back to Java

Java · Hard · Pro

Virtual thread pinning — synchronized blocks and native code caveats?

JavaConcurrencySenior
Model answerPreview

Virtual thread pinning

A virtual thread mounts on a carrier platform thread. When it blocks in synchronized or native code during a blocking operation, it pins the carrier—reducing scalability because other virtual threads can't use…