< prev index next >

src/share/vm/classfile/dictionary.cpp

Print this page

*** 28,37 **** --- 28,38 ---- #include "classfile/dictionary.hpp" #include "classfile/protectionDomainCache.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/systemDictionaryShared.hpp" #include "memory/iterator.hpp" + #include "memory/metaspaceClosure.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" #include "runtime/orderAccess.inline.hpp" #include "utilities/hashtable.inline.hpp"
*** 278,287 **** --- 279,303 ---- f(k, probe->loader_data()); } } } + // Used to scan and relocate the classes during CDS archive dump. + void Dictionary::classes_do(MetaspaceClosure* it) { + for (int index = 0; index < table_size(); index++) { + for (DictionaryEntry* probe = bucket(index); + probe != NULL; + probe = probe->next()) { + it->push(probe->klass_addr()); + if (DumpSharedSpaces) { + ((SharedDictionaryEntry*)probe)->metaspace_pointers_do(it); + } + } + } + } + + void Dictionary::oops_do(OopClosure* f) { // Only the protection domain oops contain references into the heap. Iterate // over all of them. _pd_cache_table->oops_do(f); }
*** 406,416 **** DictionaryEntry* entry = get_entry(index, hash, name, loader_data); return entry->is_valid_protection_domain(protection_domain); } ! void Dictionary::reorder_dictionary() { // Copy all the dictionary entries into a single master list. DictionaryEntry* master_list = NULL; for (int i = 0; i < table_size(); ++i) { --- 422,432 ---- DictionaryEntry* entry = get_entry(index, hash, name, loader_data); return entry->is_valid_protection_domain(protection_domain); } ! void Dictionary::reorder_dictionary_for_sharing() { // Copy all the dictionary entries into a single master list. DictionaryEntry* master_list = NULL; for (int i = 0; i < table_size(); ++i) {
< prev index next >