Path: blob/aarch64-shenandoah-jdk8u272-b10/hotspot/src/share/vm/gc_implementation/g1/evacuationInfo.hpp
38920 views
/*1* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation.7*8* This code is distributed in the hope that it will be useful, but WITHOUT9* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or10* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License11* version 2 for more details (a copy is included in the LICENSE file that12* accompanied this code).13*14* You should have received a copy of the GNU General Public License version15* 2 along with this work; if not, write to the Free Software Foundation,16* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.17*18* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA19* or visit www.oracle.com if you need additional information or have any20* questions.21*22*/2324#ifndef SHARE_VM_GC_IMPLEMENTATION_SHARED_EVACUATIONINFO_HPP25#define SHARE_VM_GC_IMPLEMENTATION_SHARED_EVACUATIONINFO_HPP2627#include "memory/allocation.hpp"2829class EvacuationInfo : public StackObj {30uint _collectionset_regions;31uint _allocation_regions;32size_t _collectionset_used_before;33size_t _collectionset_used_after;34size_t _alloc_regions_used_before;35size_t _bytes_copied;36uint _regions_freed;3738public:39EvacuationInfo() : _collectionset_regions(0), _allocation_regions(0), _collectionset_used_before(0),40_collectionset_used_after(0), _alloc_regions_used_before(0),41_bytes_copied(0), _regions_freed(0) { }4243void set_collectionset_regions(uint collectionset_regions) {44_collectionset_regions = collectionset_regions;45}4647void set_allocation_regions(uint allocation_regions) {48_allocation_regions = allocation_regions;49}5051void set_collectionset_used_before(size_t used) {52_collectionset_used_before = used;53}5455void increment_collectionset_used_after(size_t used) {56_collectionset_used_after += used;57}5859void set_alloc_regions_used_before(size_t used) {60_alloc_regions_used_before = used;61}6263void set_bytes_copied(size_t copied) {64_bytes_copied = copied;65}6667void set_regions_freed(uint freed) {68_regions_freed += freed;69}7071uint collectionset_regions() { return _collectionset_regions; }72uint allocation_regions() { return _allocation_regions; }73size_t collectionset_used_before() { return _collectionset_used_before; }74size_t collectionset_used_after() { return _collectionset_used_after; }75size_t alloc_regions_used_before() { return _alloc_regions_used_before; }76size_t bytes_copied() { return _bytes_copied; }77uint regions_freed() { return _regions_freed; }78};7980#endif // SHARE_VM_GC_IMPLEMENTATION_SHARED_EVACUATIONINFO_HPP818283