< prev index next >

src/hotspot/share/gc/z/zNMethodData.cpp


*** 74,97 **** bool ZNMethodDataOops::has_non_immediates() const { return _has_non_immediates; } ! ZNMethodData* ZNMethodData::create(nmethod* nm) { ! void* const mem = ZNMethodAllocator::allocate(sizeof(ZNMethodData)); ! return ::new (mem) ZNMethodData(nm); ! } ! ! void ZNMethodData::destroy(ZNMethodData* data) { ! ZNMethodAllocator::free(data->oops()); ! ZNMethodAllocator::free(data); ! } ! ! ZNMethodData::ZNMethodData(nmethod* nm) : _lock(), _oops(NULL) {} ZReentrantLock* ZNMethodData::lock() { return &_lock; } ZNMethodDataOops* ZNMethodData::oops() const { --- 74,91 ---- bool ZNMethodDataOops::has_non_immediates() const { return _has_non_immediates; } ! ZNMethodData::ZNMethodData() : _lock(), _oops(NULL) {} + ZNMethodData::~ZNMethodData() { + ZNMethodAllocator::free(_oops); + } + ZReentrantLock* ZNMethodData::lock() { return &_lock; } ZNMethodDataOops* ZNMethodData::oops() const {
< prev index next >