< prev index next >
src/hotspot/share/oops/weakHandle.cpp
Print this page
rev 50281 : 8195097: Make it possible to process StringTable outside safepoint
Reviewed-by:
*** 22,31 ****
--- 22,32 ----
*
*/
#include "precompiled.hpp"
#include "classfile/systemDictionary.hpp"
+ #include "classfile/stringTable.hpp"
#include "gc/shared/oopStorage.hpp"
#include "oops/access.inline.hpp"
#include "oops/oop.hpp"
#include "oops/weakHandle.inline.hpp"
#include "utilities/debug.hpp"
*** 33,42 ****
--- 34,47 ----
template <> OopStorage* WeakHandle<vm_class_loader_data>::get_storage() {
return SystemDictionary::vm_weak_oop_storage();
}
+ template <> OopStorage* WeakHandle<vm_string_table_data>::get_storage() {
+ return StringTable::weak_storage();
+ }
+
template <WeakHandleType T>
WeakHandle<T> WeakHandle<T>::create(Handle obj) {
assert(obj() != NULL, "no need to create weak null oop");
oop* oop_addr = get_storage()->allocate();
if (oop_addr == NULL) {
*** 66,71 ****
--- 71,77 ----
st->print("WeakHandle: " PTR_FORMAT, p2i(peek()));
}
// Provide instantiation.
template class WeakHandle<vm_class_loader_data>;
+ template class WeakHandle<vm_string_table_data>;
< prev index next >