< prev index next >

src/share/vm/runtime/java.cpp

Print this page




  42 #include "oops/oop.inline.hpp"
  43 #include "oops/symbol.hpp"
  44 #include "prims/jvmtiExport.hpp"
  45 #include "runtime/arguments.hpp"
  46 #include "runtime/biasedLocking.hpp"
  47 #include "runtime/compilationPolicy.hpp"
  48 #include "runtime/fprofiler.hpp"
  49 #include "runtime/init.hpp"
  50 #include "runtime/interfaceSupport.hpp"
  51 #include "runtime/java.hpp"
  52 #include "runtime/memprofiler.hpp"
  53 #include "runtime/sharedRuntime.hpp"
  54 #include "runtime/statSampler.hpp"
  55 #include "runtime/sweeper.hpp"
  56 #include "runtime/task.hpp"
  57 #include "runtime/thread.inline.hpp"
  58 #include "runtime/timer.hpp"
  59 #include "runtime/vm_operations.hpp"
  60 #include "services/memTracker.hpp"
  61 #include "trace/tracing.hpp"


  62 #include "utilities/dtrace.hpp"
  63 #include "utilities/globalDefinitions.hpp"
  64 #include "utilities/histogram.hpp"
  65 #include "utilities/macros.hpp"
  66 #include "utilities/vmError.hpp"
  67 #ifdef TARGET_ARCH_x86
  68 # include "vm_version_x86.hpp"
  69 #endif
  70 #ifdef TARGET_ARCH_sparc
  71 # include "vm_version_sparc.hpp"
  72 #endif
  73 #ifdef TARGET_ARCH_zero
  74 # include "vm_version_zero.hpp"
  75 #endif
  76 #ifdef TARGET_ARCH_arm
  77 # include "vm_version_arm.hpp"
  78 #endif
  79 #ifdef TARGET_ARCH_ppc
  80 # include "vm_version_ppc.hpp"
  81 #endif


 467       assert(_before_exit_status == BEFORE_EXIT_DONE, "invalid state");
 468       return;
 469     case BEFORE_EXIT_DONE:
 470       return;
 471     }
 472   }
 473 
 474   // The only difference between this and Win32's _onexit procs is that
 475   // this version is invoked before any threads get killed.
 476   ExitProc* current = exit_procs;
 477   while (current != NULL) {
 478     ExitProc* next = current->next();
 479     current->evaluate();
 480     delete current;
 481     current = next;
 482   }
 483 
 484   // Hang forever on exit if we're reporting an error.
 485   if (ShowMessageBoxOnError && is_error_reported()) {
 486     os::infinite_sleep();







 487   }
 488 
 489   // Terminate watcher thread - must before disenrolling any periodic task
 490   if (PeriodicTask::num_tasks() > 0)
 491     WatcherThread::stop();
 492 
 493   // Print statistics gathered (profiling ...)
 494   if (Arguments::has_profile()) {
 495     FlatProfiler::disengage();
 496     FlatProfiler::print(10);
 497   }
 498 
 499   // shut down the StatSampler task
 500   StatSampler::disengage();
 501   StatSampler::destroy();
 502 
 503   // Stop concurrent GC threads
 504   Universe::heap()->stop();
 505 
 506   // Print GC/heap related information.




  42 #include "oops/oop.inline.hpp"
  43 #include "oops/symbol.hpp"
  44 #include "prims/jvmtiExport.hpp"
  45 #include "runtime/arguments.hpp"
  46 #include "runtime/biasedLocking.hpp"
  47 #include "runtime/compilationPolicy.hpp"
  48 #include "runtime/fprofiler.hpp"
  49 #include "runtime/init.hpp"
  50 #include "runtime/interfaceSupport.hpp"
  51 #include "runtime/java.hpp"
  52 #include "runtime/memprofiler.hpp"
  53 #include "runtime/sharedRuntime.hpp"
  54 #include "runtime/statSampler.hpp"
  55 #include "runtime/sweeper.hpp"
  56 #include "runtime/task.hpp"
  57 #include "runtime/thread.inline.hpp"
  58 #include "runtime/timer.hpp"
  59 #include "runtime/vm_operations.hpp"
  60 #include "services/memTracker.hpp"
  61 #include "trace/tracing.hpp"
  62 #include "evtrace/traceEvents.hpp"
  63 #include "evtrace/traceManager.hpp"
  64 #include "utilities/dtrace.hpp"
  65 #include "utilities/globalDefinitions.hpp"
  66 #include "utilities/histogram.hpp"
  67 #include "utilities/macros.hpp"
  68 #include "utilities/vmError.hpp"
  69 #ifdef TARGET_ARCH_x86
  70 # include "vm_version_x86.hpp"
  71 #endif
  72 #ifdef TARGET_ARCH_sparc
  73 # include "vm_version_sparc.hpp"
  74 #endif
  75 #ifdef TARGET_ARCH_zero
  76 # include "vm_version_zero.hpp"
  77 #endif
  78 #ifdef TARGET_ARCH_arm
  79 # include "vm_version_arm.hpp"
  80 #endif
  81 #ifdef TARGET_ARCH_ppc
  82 # include "vm_version_ppc.hpp"
  83 #endif


 469       assert(_before_exit_status == BEFORE_EXIT_DONE, "invalid state");
 470       return;
 471     case BEFORE_EXIT_DONE:
 472       return;
 473     }
 474   }
 475 
 476   // The only difference between this and Win32's _onexit procs is that
 477   // this version is invoked before any threads get killed.
 478   ExitProc* current = exit_procs;
 479   while (current != NULL) {
 480     ExitProc* next = current->next();
 481     current->evaluate();
 482     delete current;
 483     current = next;
 484   }
 485 
 486   // Hang forever on exit if we're reporting an error.
 487   if (ShowMessageBoxOnError && is_error_reported()) {
 488     os::infinite_sleep();
 489   }
 490 
 491   if (EnableEventTracing)
 492   {
 493     HandleMark hm;
 494     EXCEPTION_MARK;
 495     TraceManager::finish_and_destroy(CHECK);
 496   }
 497 
 498   // Terminate watcher thread - must before disenrolling any periodic task
 499   if (PeriodicTask::num_tasks() > 0)
 500     WatcherThread::stop();
 501 
 502   // Print statistics gathered (profiling ...)
 503   if (Arguments::has_profile()) {
 504     FlatProfiler::disengage();
 505     FlatProfiler::print(10);
 506   }
 507 
 508   // shut down the StatSampler task
 509   StatSampler::disengage();
 510   StatSampler::destroy();
 511 
 512   // Stop concurrent GC threads
 513   Universe::heap()->stop();
 514 
 515   // Print GC/heap related information.


< prev index next >