13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 * 23 */ 24 25 #include "precompiled.hpp" 26 #include "classfile/classLoader.hpp" 27 #include "classfile/symbolTable.hpp" 28 #include "classfile/systemDictionary.hpp" 29 #include "code/codeCache.hpp" 30 #include "compiler/compileBroker.hpp" 31 #include "compiler/compilerOracle.hpp" 32 #include "interpreter/bytecodeHistogram.hpp" 33 #include "jfr/jfrEvents.hpp" 34 #include "jfr/support/jfrThreadId.hpp" 35 #include "memory/genCollectedHeap.hpp" 36 #include "memory/oopFactory.hpp" 37 #include "memory/universe.hpp" 38 #include "oops/constantPool.hpp" 39 #include "oops/generateOopMap.hpp" 40 #include "oops/instanceKlass.hpp" 41 #include "oops/instanceOop.hpp" 42 #include "oops/method.hpp" 43 #include "oops/objArrayOop.hpp" 44 #include "oops/oop.inline.hpp" 45 #include "oops/symbol.hpp" 46 #include "prims/jvmtiExport.hpp" 47 #include "runtime/arguments.hpp" 48 #include "runtime/biasedLocking.hpp" 49 #include "runtime/compilationPolicy.hpp" 50 #include "runtime/fprofiler.hpp" 51 #include "runtime/init.hpp" 52 #include "runtime/interfaceSupport.hpp" 53 #include "runtime/java.hpp" 54 #include "runtime/memprofiler.hpp" 508 Universe::heap()->stop(); 509 510 // Print GC/heap related information. 511 if (PrintGCDetails) { 512 Universe::print(); 513 AdaptiveSizePolicyOutput(0); 514 if (Verbose) { 515 ClassLoaderDataGraph::dump_on(gclog_or_tty); 516 } 517 } 518 519 if (PrintBytecodeHistogram) { 520 BytecodeHistogram::print(); 521 } 522 523 if (JvmtiExport::should_post_thread_life()) { 524 JvmtiExport::post_thread_end(thread); 525 } 526 527 528 EventThreadEnd event; 529 if (event.should_commit()) { 530 event.set_thread(JFR_THREAD_ID(thread)); 531 event.commit(); 532 } 533 534 JFR_ONLY(Jfr::on_vm_shutdown();) 535 536 // Always call even when there are not JVMTI environments yet, since environments 537 // may be attached late and JVMTI must track phases of VM execution 538 JvmtiExport::post_vm_death(); 539 Threads::shutdown_vm_agents(); 540 541 // Terminate the signal thread 542 // Note: we don't wait until it actually dies. 543 os::terminate_signal_thread(); 544 545 print_statistics(); 546 Universe::heap()->print_tracing_info(); 547 548 { MutexLocker ml(BeforeExit_lock); 549 _before_exit_status = BEFORE_EXIT_DONE; 550 BeforeExit_lock->notify_all(); 551 } 552 | 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 * 23 */ 24 25 #include "precompiled.hpp" 26 #include "classfile/classLoader.hpp" 27 #include "classfile/symbolTable.hpp" 28 #include "classfile/systemDictionary.hpp" 29 #include "code/codeCache.hpp" 30 #include "compiler/compileBroker.hpp" 31 #include "compiler/compilerOracle.hpp" 32 #include "interpreter/bytecodeHistogram.hpp" 33 #if INCLUDE_JFR 34 #include "jfr/jfrEvents.hpp" 35 #include "jfr/support/jfrThreadId.hpp" 36 #endif 37 #include "memory/genCollectedHeap.hpp" 38 #include "memory/oopFactory.hpp" 39 #include "memory/universe.hpp" 40 #include "oops/constantPool.hpp" 41 #include "oops/generateOopMap.hpp" 42 #include "oops/instanceKlass.hpp" 43 #include "oops/instanceOop.hpp" 44 #include "oops/method.hpp" 45 #include "oops/objArrayOop.hpp" 46 #include "oops/oop.inline.hpp" 47 #include "oops/symbol.hpp" 48 #include "prims/jvmtiExport.hpp" 49 #include "runtime/arguments.hpp" 50 #include "runtime/biasedLocking.hpp" 51 #include "runtime/compilationPolicy.hpp" 52 #include "runtime/fprofiler.hpp" 53 #include "runtime/init.hpp" 54 #include "runtime/interfaceSupport.hpp" 55 #include "runtime/java.hpp" 56 #include "runtime/memprofiler.hpp" 510 Universe::heap()->stop(); 511 512 // Print GC/heap related information. 513 if (PrintGCDetails) { 514 Universe::print(); 515 AdaptiveSizePolicyOutput(0); 516 if (Verbose) { 517 ClassLoaderDataGraph::dump_on(gclog_or_tty); 518 } 519 } 520 521 if (PrintBytecodeHistogram) { 522 BytecodeHistogram::print(); 523 } 524 525 if (JvmtiExport::should_post_thread_life()) { 526 JvmtiExport::post_thread_end(thread); 527 } 528 529 530 #if INCLUDE_JFR 531 EventThreadEnd event; 532 if (event.should_commit()) { 533 event.set_thread(JFR_THREAD_ID(thread)); 534 event.commit(); 535 } 536 #endif 537 538 JFR_ONLY(Jfr::on_vm_shutdown();) 539 540 // Always call even when there are not JVMTI environments yet, since environments 541 // may be attached late and JVMTI must track phases of VM execution 542 JvmtiExport::post_vm_death(); 543 Threads::shutdown_vm_agents(); 544 545 // Terminate the signal thread 546 // Note: we don't wait until it actually dies. 547 os::terminate_signal_thread(); 548 549 print_statistics(); 550 Universe::heap()->print_tracing_info(); 551 552 { MutexLocker ml(BeforeExit_lock); 553 _before_exit_status = BEFORE_EXIT_DONE; 554 BeforeExit_lock->notify_all(); 555 } 556 |