< prev index next >

src/hotspot/share/runtime/sharedRuntime.cpp

Print this page
rev 52801 : Upstream/backport Shenandoah to JDK11u
* * *
[backport] 8237570: Shenandoah: cleanup uses of allocation/free threshold in static heuristics
Reviewed-by: rkennke

*** 2878,2887 **** --- 2878,2905 ---- // Lock and unlock a critical section to give the system a chance to block GCLocker::lock_critical(thread); GCLocker::unlock_critical(thread); JRT_END + JRT_LEAF(oopDesc*, SharedRuntime::pin_object(JavaThread* thread, oopDesc* obj)) + assert(Universe::heap()->supports_object_pinning(), "Why we here?"); + assert(UseShenandoahGC, "only supported in Shenandoah for now"); + assert(obj != NULL, "Should not be null"); + oop o(obj); + o = Universe::heap()->pin_object(thread, o); + assert(o != NULL, "Should not be null"); + return o; + JRT_END + + JRT_LEAF(void, SharedRuntime::unpin_object(JavaThread* thread, oopDesc* obj)) + assert(Universe::heap()->supports_object_pinning(), "Why we here?"); + assert(UseShenandoahGC, "only supported in Shenandoah for now"); + assert(obj != NULL, "Should not be null"); + oop o(obj); + Universe::heap()->unpin_object(thread, o); + JRT_END + // ------------------------------------------------------------------------- // Java-Java calling convention // (what you use when Java calls Java) //------------------------------name_for_receiver----------------------------------
< prev index next >