< prev index next >

src/share/vm/prims/whitebox.cpp

Print this page
rev 12504 : [mq]: whitebox

@@ -353,10 +353,21 @@
 WB_ENTRY(jlong, WB_GetHeapAlignment(JNIEnv* env, jobject o))
   size_t alignment = Universe::heap()->collector_policy()->heap_alignment();
   return (jlong)alignment;
 WB_END
 
+WB_ENTRY(jboolean, WB_SupportsConcurrentGCPhaseControl(JNIEnv* env, jobject o))
+  return Universe::heap()->supports_concurrent_phase_control();
+WB_END
+
+WB_ENTRY(jboolean, WB_RequestConcurrentGCPhase(JNIEnv* env, jobject o, jstring name))
+  Handle h_name(THREAD, JNIHandles::resolve(name));
+  ResourceMark rm;
+  const char* c_name = java_lang_String::as_utf8_string(h_name());
+  return Universe::heap()->request_concurrent_phase(c_name);
+WB_END
+
 #if INCLUDE_ALL_GCS
 WB_ENTRY(jboolean, WB_G1IsHumongous(JNIEnv* env, jobject o, jobject obj))
   G1CollectedHeap* g1 = G1CollectedHeap::heap();
   oop result = JNIHandles::resolve(obj);
   const HeapRegion* hr = g1->heap_region_containing(result);

@@ -1903,10 +1914,13 @@
                                                       (void*)&WB_AddCompilerDirective },
   {CC"removeCompilerDirective",   CC"(I)V",             (void*)&WB_RemoveCompilerDirective },
   {CC"currentGC",                 CC"()I",            (void*)&WB_CurrentGC},
   {CC"allSupportedGC",            CC"()I",            (void*)&WB_AllSupportedGC},
   {CC"gcSelectedByErgo",          CC"()Z",            (void*)&WB_GCSelectedByErgo},
+  {CC"supportsConcurrentGCPhaseControl", CC"()Z",     (void*)&WB_SupportsConcurrentGCPhaseControl},
+  {CC"requestConcurrentGCPhase0", CC"(Ljava/lang/String;)Z",
+                                                      (void*)&WB_RequestConcurrentGCPhase},
 };
 
 #undef CC
 
 JVM_ENTRY(void, JVM_RegisterWhiteBoxMethods(JNIEnv* env, jclass wbclass))
< prev index next >