8230096: ZGC: Remove unused ZObjectAllocator::_nworkers

Reviewed-by: stefank
This commit is contained in:
Per Lidén 2019-08-28 09:50:23 +02:00
parent 536122fed6
commit 2750569c00
3 changed files with 3 additions and 5 deletions

View File

@ -64,7 +64,7 @@ ZHeap* ZHeap::_heap = NULL;
ZHeap::ZHeap() : ZHeap::ZHeap() :
_workers(), _workers(),
_object_allocator(_workers.nworkers()), _object_allocator(),
_page_allocator(heap_min_size(), heap_initial_size(), heap_max_size(), heap_max_reserve_size()), _page_allocator(heap_min_size(), heap_initial_size(), heap_max_size(), heap_max_reserve_size()),
_page_table(), _page_table(),
_forwarding_table(), _forwarding_table(),

View File

@ -41,8 +41,7 @@
static const ZStatCounter ZCounterUndoObjectAllocationSucceeded("Memory", "Undo Object Allocation Succeeded", ZStatUnitOpsPerSecond); static const ZStatCounter ZCounterUndoObjectAllocationSucceeded("Memory", "Undo Object Allocation Succeeded", ZStatUnitOpsPerSecond);
static const ZStatCounter ZCounterUndoObjectAllocationFailed("Memory", "Undo Object Allocation Failed", ZStatUnitOpsPerSecond); static const ZStatCounter ZCounterUndoObjectAllocationFailed("Memory", "Undo Object Allocation Failed", ZStatUnitOpsPerSecond);
ZObjectAllocator::ZObjectAllocator(uint nworkers) : ZObjectAllocator::ZObjectAllocator() :
_nworkers(nworkers),
_used(0), _used(0),
_undone(0), _undone(0),
_shared_medium_page(NULL), _shared_medium_page(NULL),

View File

@ -31,7 +31,6 @@
class ZObjectAllocator { class ZObjectAllocator {
private: private:
const uint _nworkers;
ZPerCPU<size_t> _used; ZPerCPU<size_t> _used;
ZPerCPU<size_t> _undone; ZPerCPU<size_t> _undone;
ZContended<ZPage*> _shared_medium_page; ZContended<ZPage*> _shared_medium_page;
@ -64,7 +63,7 @@ private:
bool undo_alloc_object(ZPage* page, uintptr_t addr, size_t size); bool undo_alloc_object(ZPage* page, uintptr_t addr, size_t size);
public: public:
ZObjectAllocator(uint nworkers); ZObjectAllocator();
uintptr_t alloc_object(size_t size); uintptr_t alloc_object(size_t size);