comparison src/share/vm/runtime/safepoint.cpp @ 6162:e9140bf80b4a

7158800: Improve storage of symbol tables Summary: Use an alternate version of hashing algorithm for symbol string tables and after a certain bucket size to improve performance Reviewed-by: pbk, kamg, dlong, kvn, fparain
author coleenp
date Wed, 13 Jun 2012 19:52:59 -0400
parents 541c4a5e7b88
children d2a62e0f25eb
comparison
equal deleted inserted replaced
6129:4d399f013e5a 6162:e9140bf80b4a
21 * questions. 21 * questions.
22 * 22 *
23 */ 23 */
24 24
25 #include "precompiled.hpp" 25 #include "precompiled.hpp"
26 #include "classfile/symbolTable.hpp"
26 #include "classfile/systemDictionary.hpp" 27 #include "classfile/systemDictionary.hpp"
27 #include "code/codeCache.hpp" 28 #include "code/codeCache.hpp"
28 #include "code/icBuffer.hpp" 29 #include "code/icBuffer.hpp"
29 #include "code/nmethod.hpp" 30 #include "code/nmethod.hpp"
30 #include "code/pcDesc.hpp" 31 #include "code/pcDesc.hpp"
524 { 525 {
525 TraceTime t3("compilation policy safepoint handler", TraceSafepointCleanupTime); 526 TraceTime t3("compilation policy safepoint handler", TraceSafepointCleanupTime);
526 CompilationPolicy::policy()->do_safepoint_work(); 527 CompilationPolicy::policy()->do_safepoint_work();
527 } 528 }
528 529
529 TraceTime t4("sweeping nmethods", TraceSafepointCleanupTime); 530 {
530 NMethodSweeper::scan_stacks(); 531 TraceTime t4("sweeping nmethods", TraceSafepointCleanupTime);
532 NMethodSweeper::scan_stacks();
533 }
534
535 if (SymbolTable::needs_rehashing()) {
536 TraceTime t5("rehashing symbol table", TraceSafepointCleanupTime);
537 SymbolTable::rehash_table();
538 }
539
540 if (StringTable::needs_rehashing()) {
541 TraceTime t6("rehashing string table", TraceSafepointCleanupTime);
542 StringTable::rehash_table();
543 }
531 544
532 // rotate log files? 545 // rotate log files?
533 if (UseGCLogFileRotation) { 546 if (UseGCLogFileRotation) {
534 gclog_or_tty->rotate_log(); 547 gclog_or_tty->rotate_log();
535 } 548 }