< prev index next >

src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp

Print this page
rev 58687 : Shenandoah: New incremental-update mode
rev 58688 : [mq]: JDK-8242054-04.patch


 392   log_info(gc, init)("Safepointing mechanism: thread-local poll");
 393 
 394   return JNI_OK;
 395 }
 396 
 397 void ShenandoahHeap::initialize_heuristics() {
 398   if (ShenandoahGCMode != NULL) {
 399     if (strcmp(ShenandoahGCMode, "normal") == 0) {
 400       _gc_mode = new ShenandoahNormalMode();
 401     } else if (strcmp(ShenandoahGCMode, "iu") == 0) {
 402       _gc_mode = new ShenandoahIUMode();
 403     } else if (strcmp(ShenandoahGCMode, "passive") == 0) {
 404       _gc_mode = new ShenandoahPassiveMode();
 405     } else {
 406       vm_exit_during_initialization("Unknown -XX:ShenandoahGCMode option");
 407     }
 408   } else {
 409     ShouldNotReachHere();
 410   }
 411   _gc_mode->initialize_flags();













 412   _heuristics = _gc_mode->initialize_heuristics();
 413 
 414   if (_heuristics->is_diagnostic() && !UnlockDiagnosticVMOptions) {
 415     vm_exit_during_initialization(
 416             err_msg("Heuristics \"%s\" is diagnostic, and must be enabled via -XX:+UnlockDiagnosticVMOptions.",
 417                     _heuristics->name()));
 418   }
 419   if (_heuristics->is_experimental() && !UnlockExperimentalVMOptions) {
 420     vm_exit_during_initialization(
 421             err_msg("Heuristics \"%s\" is experimental, and must be enabled via -XX:+UnlockExperimentalVMOptions.",
 422                     _heuristics->name()));
 423   }
 424   log_info(gc, init)("Shenandoah heuristics: %s",
 425                      _heuristics->name());
 426 }
 427 
 428 #ifdef _MSC_VER
 429 #pragma warning( push )
 430 #pragma warning( disable:4355 ) // 'this' : used in base member initializer list
 431 #endif




 392   log_info(gc, init)("Safepointing mechanism: thread-local poll");
 393 
 394   return JNI_OK;
 395 }
 396 
 397 void ShenandoahHeap::initialize_heuristics() {
 398   if (ShenandoahGCMode != NULL) {
 399     if (strcmp(ShenandoahGCMode, "normal") == 0) {
 400       _gc_mode = new ShenandoahNormalMode();
 401     } else if (strcmp(ShenandoahGCMode, "iu") == 0) {
 402       _gc_mode = new ShenandoahIUMode();
 403     } else if (strcmp(ShenandoahGCMode, "passive") == 0) {
 404       _gc_mode = new ShenandoahPassiveMode();
 405     } else {
 406       vm_exit_during_initialization("Unknown -XX:ShenandoahGCMode option");
 407     }
 408   } else {
 409     ShouldNotReachHere();
 410   }
 411   _gc_mode->initialize_flags();
 412   if (_gc_mode->is_diagnostic() && !UnlockDiagnosticVMOptions) {
 413     vm_exit_during_initialization(
 414             err_msg("GC mode \"%s\" is diagnostic, and must be enabled via -XX:+UnlockDiagnosticVMOptions.",
 415                     _gc_mode->name()));
 416   }
 417   if (_gc_mode->is_experimental() && !UnlockExperimentalVMOptions) {
 418     vm_exit_during_initialization(
 419             err_msg("GC mode \"%s\" is experimental, and must be enabled via -XX:+UnlockExperimentalVMOptions.",
 420                     _gc_mode->name()));
 421   }
 422   log_info(gc, init)("Shenandoah GC mode: %s",
 423                      _gc_mode->name());
 424 
 425   _heuristics = _gc_mode->initialize_heuristics();
 426 
 427   if (_heuristics->is_diagnostic() && !UnlockDiagnosticVMOptions) {
 428     vm_exit_during_initialization(
 429             err_msg("Heuristics \"%s\" is diagnostic, and must be enabled via -XX:+UnlockDiagnosticVMOptions.",
 430                     _heuristics->name()));
 431   }
 432   if (_heuristics->is_experimental() && !UnlockExperimentalVMOptions) {
 433     vm_exit_during_initialization(
 434             err_msg("Heuristics \"%s\" is experimental, and must be enabled via -XX:+UnlockExperimentalVMOptions.",
 435                     _heuristics->name()));
 436   }
 437   log_info(gc, init)("Shenandoah heuristics: %s",
 438                      _heuristics->name());
 439 }
 440 
 441 #ifdef _MSC_VER
 442 #pragma warning( push )
 443 #pragma warning( disable:4355 ) // 'this' : used in base member initializer list
 444 #endif


< prev index next >