src/hotspot/share/classfile/stringTable.cpp
changeset 52402 72d4e10305b9
parent 52062 8dbf1a13af49
child 52516 d5eebe1e03fe
equal deleted inserted replaced
52401:595ab4f025d7 52402:72d4e10305b9
    76 > _shared_table;
    76 > _shared_table;
    77 #endif
    77 #endif
    78 
    78 
    79 // --------------------------------------------------------------------------
    79 // --------------------------------------------------------------------------
    80 StringTable* StringTable::_the_table = NULL;
    80 StringTable* StringTable::_the_table = NULL;
    81 volatile bool StringTable::_shared_string_mapped = false;
       
    82 volatile bool StringTable::_alt_hash = false;
    81 volatile bool StringTable::_alt_hash = false;
    83 
    82 
    84 static juint murmur_seed = 0;
    83 static juint murmur_seed = 0;
    85 
    84 
    86 uintx hash_string(const jchar* s, int len, bool useAlt) {
    85 uintx hash_string(const jchar* s, int len, bool useAlt) {
   869   _shared_table.serialize_header(soc);
   868   _shared_table.serialize_header(soc);
   870 
   869 
   871   if (soc->writing()) {
   870   if (soc->writing()) {
   872     // Sanity. Make sure we don't use the shared table at dump time
   871     // Sanity. Make sure we don't use the shared table at dump time
   873     _shared_table.reset();
   872     _shared_table.reset();
   874   } else if (!_shared_string_mapped) {
   873   } else if (!HeapShared::closed_archive_heap_region_mapped()) {
   875     _shared_table.reset();
   874     _shared_table.reset();
   876   }
   875   }
   877 }
   876 }
   878 
   877 
   879 class SharedStringIterator {
   878 class SharedStringIterator {