@@ -1,7 +1,7 @@ /* - * Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2024, 2026, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
@@ -38,24 +38,10 @@ #include "utilities/macros.hpp" class MemRegion; #if INCLUDE_CDS_JAVA_HEAP - class DumpedInternedStrings : - public ResizeableHashTable<oop, bool, - AnyObj::C_HEAP, - mtClassShared, - HeapShared::string_oop_hash> - { - public: - DumpedInternedStrings(unsigned size, unsigned max_size) : - ResizeableHashTable<oop, bool, - AnyObj::C_HEAP, - mtClassShared, - HeapShared::string_oop_hash>(size, max_size) {} - }; - class AOTMappedHeapWriter : AllStatic { friend class HeapShared; friend class AOTMappedHeapLoader; // AOTMappedHeapWriter manipulates three types of addresses: //
@@ -129,11 +115,10 @@ static address _requested_bottom; // The requested address of the lowest archived heap object static address _requested_top; // The exclusive end of the highest archived heap object static GrowableArrayCHeap<NativePointerInfo, mtClassShared>* _native_pointers; static GrowableArrayCHeap<oop, mtClassShared>* _source_objs; - static DumpedInternedStrings *_dumped_interned_strings; // We sort _source_objs_order to minimize the number of bits in ptrmap and oopmap. // See comments near the body of AOTMappedHeapWriter::compare_objs_by_oop_fields(). // The objects will be written in the order of: //_source_objs->at(_source_objs_order->at(0)._index)
@@ -188,10 +173,11 @@ static void root_segment_at_put(objArrayOop segment, int index, oop root); static objArrayOop allocate_root_segment(size_t offset, int element_count); static void copy_roots_to_buffer(GrowableArrayCHeap<oop, mtClassShared>* roots); static void copy_source_objs_to_buffer(GrowableArrayCHeap<oop, mtClassShared>* roots); static size_t copy_one_source_obj_to_buffer(oop src_obj); + static void update_stats(oop src_obj); static void maybe_fill_gc_region_gap(size_t required_byte_size); static size_t filler_array_byte_size(int length); static int filler_array_length(size_t fill_bytes); static HeapWord* init_filler_array_at_buffer_top(int array_length, size_t fill_bytes);
@@ -225,12 +211,10 @@ static void delete_tables_with_raw_oops(); static void add_source_obj(oop src_obj); static bool is_too_large_to_archive(size_t size); static bool is_too_large_to_archive(oop obj); static bool is_string_too_large_to_archive(oop string); - static bool is_dumped_interned_string(oop o); - static void add_to_dumped_interned_strings(oop string); static void write(GrowableArrayCHeap<oop, mtClassShared>*, ArchiveMappedHeapInfo* heap_info); static address requested_address(); // requested address of the lowest achived heap object static size_t get_filler_size_at(address buffered_addr); static void mark_native_pointer(oop src_obj, int offset);