/arkcompiler/ets_runtime/ecmascript/mem/ |
D | region-inl.h | 26 inline RememberedSet *Region::CreateRememberedSet() in CreateRememberedSet() 36 inline RememberedSet *Region::GetOrCreateCrossRegionRememberedSet() in GetOrCreateCrossRegionRememberedSet() 47 inline RememberedSet *Region::GetOrCreateOldToNewRememberedSet() in GetOrCreateOldToNewRememberedSet() 63 inline void Region::MergeRSetForConcurrentSweeping() in MergeRSetForConcurrentSweeping() 78 inline GCBitset *Region::GetMarkGCBitset() const in GetMarkGCBitset() 83 inline bool Region::AtomicMark(void *address) in AtomicMark() 91 inline void Region::ClearMark(void *address) in ClearMark() 98 inline bool Region::Test(void *addr) const in Test() 106 inline bool Region::TestOldToNew(uintptr_t addr) in TestOldToNew() 118 inline void Region::IterateAllMarkedBits(Visitor visitor) const in IterateAllMarkedBits() [all …]
|
D | sparse_space.h | 27 Region::ObjectAddressToRange(object)->IncreaseAliveObject(size); \ 37 Region::ObjectAddressToRange(object)->IncreaseAliveObject(size); \ 78 void AddSweepingRegion(Region *region); 80 Region *GetSweepingRegionSafe(); 81 void AddSweptRegionSafe(Region *region); 82 Region *GetSweptRegionSafe(); 83 void FreeRegionFromSpace(Region *region); 84 Region *TryToGetSuitableSweptRegion(size_t size); 86 void FreeRegion(Region *current, bool isMain = true); 87 void FreeLiveRange(Region *current, uintptr_t freeStart, uintptr_t freeEnd, bool isMain); [all …]
|
D | sparse_space.cpp | 37 Region *region = heapRegionAllocator_->AllocateAlignedRegion(this, DEFAULT_REGION_SIZE, in Initialize() 93 …Region *region = heapRegionAllocator_->AllocateAlignedRegion(this, DEFAULT_REGION_SIZE, heap_->Get… in Expand() 118 EnumerateRegions([this](Region *current) { in PrepareSweeping() 133 Region *current = GetSweepingRegionSafe(); in AsyncSweep() 151 EnumerateRegions([this](Region *current) { in Sweep() 165 Region *region = nullptr; in TryFillSweptRegion() 181 void SparseSpace::AddSweepingRegion(Region *region) in AddSweepingRegion() 189 std::sort(sweepingList_.begin(), sweepingList_.end(), [](Region *first, Region *second) { in SortSweepingRegion() 194 Region *SparseSpace::GetSweepingRegionSafe() in GetSweepingRegionSafe() 197 Region *region = nullptr; in GetSweepingRegionSafe() [all …]
|
D | verification.cpp | 28 Region *region = Region::ObjectAddressToRange(obj); in LogErrorForObjSlot() 29 Region *valueRegion = Region::ObjectAddressToRange(value); in LogErrorForObjSlot() 30 Region *slotRegion = Region::ObjectAddressToRange(slotValue); in LogErrorForObjSlot() 55 Region *region = Region::ObjectAddressToRange(obj); in LogErrorForObj() 71 Region *objectRegion = Region::ObjectAddressToRange(object); in VerifyInactiveSemiSpaceMarkedObject() 81 Region *valueRegion = Region::ObjectAddressToRange(value); in VerifyInactiveSemiSpaceMarkedObject() 167 Region *objectRegion = Region::ObjectAddressToRange(object); in VerifyMarkYoung() 168 Region *valueRegion = Region::ObjectAddressToRange(value); in VerifyMarkYoung() 195 Region *objectRegion = Region::ObjectAddressToRange(object); in VerifyEvacuateYoung() 196 Region *valueRegion = Region::ObjectAddressToRange(value); in VerifyEvacuateYoung() [all …]
|
D | parallel_evacuator.h | 78 …Workload(ParallelEvacuator *evacuator, Region *region) : evacuator_(evacuator), region_(region) {}; in Workload() 81 inline Region *GetRegion() const in GetRegion() 92 Region *region_; 97 … EvacuateWorkload(ParallelEvacuator *evacuator, Region *region) : Workload(evacuator, region) {} in EvacuateWorkload() 104 … UpdateRSetWorkload(ParallelEvacuator *evacuator, Region *region) : Workload(evacuator, region) {} in UpdateRSetWorkload() 111 …UpdateNewRegionWorkload(ParallelEvacuator *evacuator, Region *region) : Workload(evacuator, region… in UpdateNewRegionWorkload() 118 UpdateAndSweepNewRegionWorkload(ParallelEvacuator *evacuator, Region *region) in UpdateAndSweepNewRegionWorkload() 137 …void EvacuateRegion(TlabAllocator *allocator, Region *region, std::unordered_set<JSTaggedType> &tr… 139 inline void SetObjectRSet(ObjectSlot slot, Region *region); 141 inline bool IsWholeRegionEvacuate(Region *region); [all …]
|
D | parallel_marker-inl.h | 35 Region *rootRegion = Region::ObjectAddressToRange(root); in VisitBodyInObj() 50 inline void NonMovableMarker::MarkValue(uint32_t threadId, ObjectSlot &slot, Region *rootRegion, bo… in MarkValue() 63 Region *valueRegion = Region::ObjectAddressToRange(obj); in MarkValue() 73 Region *objectRegion = Region::ObjectAddressToRange(object); in MarkObject() 113 inline void NonMovableMarker::HandleOldToNewRSet(uint32_t threadId, Region *region) in HandleOldToNewRSet() 129 inline void NonMovableMarker::RecordWeakReference(uint32_t threadId, JSTaggedType *ref, Region *obj… in RecordWeakReference() 132 Region *valueRegion = Region::ObjectAddressToRange(value.GetTaggedWeakRef()); in RecordWeakReference() 172 Region *objectRegion = Region::ObjectAddressToRange(start.SlotAddress()); in HandleRangeRoots() 189 inline void MovableMarker::HandleOldToNewRSet(uint32_t threadId, Region *region) in HandleOldToNewRSet() 259 return Region::ObjectAddressToRange(dst)->InYoungSpace(); in UpdateForwardAddressIfFailed() [all …]
|
D | space.h | 167 Region *GetCurrentRegion() const in GetCurrentRegion() 172 Region *GetFirstRegion() const in GetFirstRegion() 182 EcmaList<Region> &GetRegionList() in GetRegionList() 187 const EcmaList<Region> &GetRegionList() const in GetRegionList() 209 inline void EnumerateRegions(const Callback &cb, Region *region = nullptr) const; 213 inline void AddRegion(Region *region); 214 inline void RemoveRegion(Region *region); 222 void ClearAndFreeRegion(Region *region, size_t cachedSize = 0); 226 EcmaList<Region> regionList_ {}; 233 Region *recordRegion_ {nullptr}; [all …]
|
D | parallel_evacuator-inl.h | 28 bool ParallelEvacuator::IsWholeRegionEvacuate(Region *region) in IsWholeRegionEvacuate() 60 Region *valueRegion = Region::ObjectAddressToRange(object); in UpdateOldToNewObjectSlot() 72 Region *dstRegion = Region::ObjectAddressToRange(dst); in UpdateOldToNewObjectSlot() 115 Region *objectRegion = Region::ObjectAddressToRange(value); in UpdateWeakObjectSlot() 143 Region *region = Region::ObjectAddressToRange(object); in SetObjectFieldRSet() 157 void ParallelEvacuator::SetObjectRSet(ObjectSlot slot, Region *region) in SetObjectRSet() 163 Region *valueRegion = Region::ObjectAddressToRange(value); in SetObjectRSet() 189 … Region *objectRegion = Region::ObjectAddressToRange(reinterpret_cast<TaggedObject *>(oldAddress)); in UpdateAddressAfterEvacation()
|
D | space.cpp | 59 …EnumerateRegions([this, &cachedSize](Region *current) { ClearAndFreeRegion(current, cachedSize); }… in ReclaimRegions() 64 void Space::ClearAndFreeRegion(Region *region, size_t cachedSize) in ClearAndFreeRegion() 103 …size_t alignedSize = AlignUp(objectSize + sizeof(Region) + HUGE_OBJECT_BITSET_SIZE, PANDA_POOL_ALI… in Allocate() 108 Region *region = heapRegionAllocator_->AllocateAlignedRegion(this, alignedSize, thread); in Allocate() 120 Region *currentRegion = GetRegionList().GetFirst(); in Sweep() 122 Region *next = currentRegion->GetNext(); in Sweep() 140 EnumerateRegions([&](Region *region) { in IterateOverObjects() 152 Region *last = hugeNeedFreeList_.PopBack(); in ReclaimHugeRegion()
|
D | allocator.h | 25 class Region; variable 91 inline void Initialize(Region *region); 96 inline void AddFree(Region *region); 101 inline bool MatchFreeObjectSet(Region *region, size_t size); 102 inline void CollectFreeObjectSet(Region *region); 103 inline void DetachFreeObjectSet(Region *region);
|
D | barriers.cpp | 21 void Barriers::Update(const JSThread *thread, uintptr_t slotAddr, Region *objectRegion, TaggedObjec… in Update() 22 Region *valueRegion, WriteBarrierType writeType) in Update() 49 Region *valueRegion = Region::ObjectAddressToRange(object); in MarkAndPushForDeserialize()
|
D | parallel_marker.h | 27 class Region; variable 43 void ProcessOldToNew(uint32_t threadId, Region *region); // for SemiGC 72 virtual inline void HandleOldToNewRSet(uint32_t threadId, Region *region) = 0; 79 [[maybe_unused]] Region *objectRegion) in RecordWeakReference() 101 … inline void MarkValue(uint32_t threadId, ObjectSlot &slot, Region *rootRegion, bool needBarrier); 109 inline void HandleOldToNewRSet(uint32_t threadId, Region *region) override; 110 …inline void RecordWeakReference(uint32_t threadId, JSTaggedType *ref, Region *objectRegion) overri… 130 inline void HandleOldToNewRSet(uint32_t threadId, Region *region) override; 152 …inline void RecordWeakReference(uint32_t threadId, JSTaggedType *ref, Region *objectRegion = nullp… 165 inline bool NeedEvacuate(Region *region); [all …]
|
D | heap_region_allocator.cpp | 30 Region *HeapRegionAllocator::AllocateAlignedRegion(Space *space, size_t capacity, JSThread* thread) in AllocateAlignedRegion() 64 …uintptr_t begin = AlignUp(mem + sizeof(Region), static_cast<size_t>(MemAlignment::MEM_ALIGN_REGION… in AllocateAlignedRegion() 67 Region *region = new (ToVoidPtr(mem)) Region(thread, mem, begin, end, flags); in AllocateAlignedRegion() 72 void HeapRegionAllocator::FreeRegion(Region *region, size_t cachedSize) in FreeRegion()
|
D | region.h | 105 class Region { 107 …Region(JSThread *thread, uintptr_t allocateBase, uintptr_t begin, uintptr_t end, RegionSpaceFlag s… in Region() function 120 ~Region() = default; 122 NO_COPY_SEMANTIC(Region); 123 NO_MOVE_SEMANTIC(Region); 125 void LinkNext(Region *next) in LinkNext() 130 Region *GetNext() const in GetNext() 135 void LinkPrev(Region *prev) in LinkPrev() 140 Region *GetPrev() const in GetPrev() 227 static Region *ObjectAddressToRange(TaggedObject *obj) in ObjectAddressToRange() [all …]
|
/arkcompiler/runtime_core/static_core/runtime/mem/ |
D | region_space.cpp | 23 uint32_t Region::GetAllocatedBytes() const in GetAllocatedBytes() 36 double Region::GetFragmentation() const in GetFragmentation() 42 InternalAllocatorPtr Region::GetInternalAllocator() in GetInternalAllocator() 47 void Region::CreateRemSet() in CreateRemSet() 53 void Region::SetupAtomics() in SetupAtomics() 59 void Region::CreateTLABSupport() in CreateTLABSupport() 65 size_t Region::GetRemainingSizeForTLABs() const in GetRemainingSizeForTLABs() 74 TLAB *Region::CreateTLAB(size_t size) in CreateTLAB() 89 MarkBitmap *Region::CreateMarkBitmap() in CreateMarkBitmap() 101 MarkBitmap *Region::CreateLiveBitmap() in CreateLiveBitmap() [all …]
|
D | region_allocator.h | 36 using RegionsVisitor = std::function<void(PandaVector<Region *> &vector)>; 39 static inline Region *ObjectToRegion(const ObjectHeader *object) in ObjectToRegion() 41 auto *region = reinterpret_cast<Region *>(((ToUintPtr(object)) & ~DEFAULT_REGION_MASK)); in ObjectToRegion() 58 static inline Region *AddrToRegion(const void *addr) in AddrToRegion() 61 return static_cast<Region *>(regionAddr); in AddrToRegion() 82 Region *GetRegion(const ObjectHeader *object) const in GetRegion() 97 PandaVector<Region *> GetAllRegions(); 117 Region *AllocRegion(size_t regionSize, RegionFlag edenOrOldOrNonmovable, RegionFlag properties) in AllocRegion() 128 …Region *CreateAndSetUpNewRegion(size_t regionSize, RegionFlag regionType, RegionFlag properties = … 214 … this->GetSpace()->IterateRegions([&](Region *region) { region->IterateOverObjects(visitor); }); in IterateOverObjects() [all …]
|
D | region_space.h | 56 class Region { 58 NO_THREAD_SANITIZE explicit Region(RegionSpace *space, uintptr_t begin, uintptr_t end) in Region() function 63 ~Region() = default; 65 NO_COPY_SEMANTIC(Region); 66 NO_MOVE_SEMANTIC(Region); 291 return AlignUp(sizeof(Region), DEFAULT_ALIGNMENT_IN_BYTES); in HeadSize() 377 static Region *AsRegion(const DListNode *node) in AsRegion() 379 return reinterpret_cast<Region *>(ToUintPtr(node) - MEMBER_OFFSET(Region, node_)); in AsRegion() 402 inline std::ostream &DumpRegionRange(std::ostream &out, const Region ®ion) in DumpRegionRange() 412 inline std::ostream &operator<<(std::ostream &out, const Region ®ion) [all …]
|
D | rem_set.h | 33 class Region; variable 56 static void InvalidateRegion(Region *invalidRegion); 59 static void InvalidateRefsFromRegion(Region *invalidRegion); 124 PandaUnorderedSet<Region *> *GetRefRegions(); 126 void AddRefRegion(Region *region); 128 void RemoveFromRegion(Region *region); 130 void RemoveRefRegion(Region *region); 135 PandaUnorderedSet<Region *> refRegions_;
|
D | rem_set-inl.h | 54 void RemSet<LockConfigT>::InvalidateRegion(Region *invalidRegion) in InvalidateRegion() 59 for (Region *refReg : invalidRemset->refRegions_) { in InvalidateRegion() 73 void RemSet<LockConfigT>::InvalidateRefsFromRegion(Region *invalidRegion) in InvalidateRefsFromRegion() 77 for (Region *refReg : invalidRemset->refRegions_) { in InvalidateRefsFromRegion() 122 auto regionPred = []([[maybe_unused]] Region *region) { return true; }; in IterateOverObjects() 123 Iterate(regionPred, [visitor](Region *region, const MemRange &range) { in IterateOverObjects() 132 PandaUnorderedSet<Region *> *RemSet<LockConfigT>::GetRefRegions() in GetRefRegions() 140 void RemSet<LockConfigT>::AddRefRegion(Region *region) in AddRefRegion() 148 void RemSet<LockConfigT>::RemoveFromRegion(Region *region) in RemoveFromRegion() 159 void RemSet<LockConfigT>::RemoveRefRegion(Region *region) in RemoveRefRegion() [all …]
|
D | region_space-inl.h | 25 explicit RegionAllocCheck(Region *region) : region_(region) in RegionAllocCheck() 37 Region *region_ FIELD_UNUSED; 42 explicit RegionIterateCheck(Region *region) : region_(region) in RegionIterateCheck() 54 Region *region_ FIELD_UNUSED; 58 void *Region::Alloc(size_t alignedSize) in Alloc() 91 void Region::IterateOverObjects(const ObjectVisitor &visitor) in IterateOverObjects() 114 void RegionPool::FreeRegion(Region *region) in FreeRegion() 128 void RegionSpace::FreeRegion(Region *region) in FreeRegion() 158 auto visitor = [this](Region *region) { regionPool_->FreeRegion<OS_PAGES_POLICY>(region); }; in ReleaseEmptyRegions() 179 auto *region = Region::AsRegion(&(*it)); in IterateRegionsList()
|
D | region_allocator-inl.h | 77 Region *RegionAllocatorBase<LockConfigT>::CreateAndSetUpNewRegion(size_t regionSize, RegionFlag reg… in CreateAndSetUpNewRegion() 80 Region *region = AllocRegion<OS_ALLOC_POLICY>(regionSize, regionType, properties); in CreateAndSetUpNewRegion() 106 PandaVector<Region *> RegionAllocatorBase<LockConfigT>::GetAllRegions() in GetAllRegions() 108 PandaVector<Region *> vector; in GetAllRegions() 110 GetSpace()->IterateRegions([&](Region *region) { vector.push_back(region); }); in GetAllRegions() 154 … Region *region = this->template CreateAndSetUpNewRegion<AllocConfigT>(REGION_SIZE, REGION_TYPE); in AllocRegular() 167 Region *regionTo = PopFromRegionQueue<IS_ATOMIC, REGION_TYPE>(); in AllocRegular() 203 Region *region = this->template CreateAndSetUpNewRegion<AllocConfigT>( in Alloc() 204 Region::RegionSize(alignSize, REGION_SIZE), REGION_TYPE, IS_LARGE_OBJECT); in Alloc() 244 Region *region = nullptr; in CreateTLAB() [all …]
|
/arkcompiler/runtime_core/static_core/runtime/mem/gc/g1/ |
D | collection_set.h | 41 explicit CollectionSet(PandaVector<Region *> &&youngRegions) : collectionSet_(youngRegions) in CollectionSet() 49 void AddRegion(Region *region) in AddRegion() 98 return Range<PandaVector<Region *>::iterator>(begin(), begin() + tenuredBegin_); in Young() 103 return Range<PandaVector<Region *>::const_iterator>(begin(), begin() + tenuredBegin_); in Young() 108 … return Range<PandaVector<Region *>::iterator>(begin() + tenuredBegin_, begin() + humongousBegin_); in Tenured() 113 …return Range<PandaVector<Region *>::const_iterator>(begin() + tenuredBegin_, begin() + humongousBe… in Tenured() 118 return Range<PandaVector<Region *>::iterator>(begin() + humongousBegin_, end()); in Humongous() 123 return Range<PandaVector<Region *>::const_iterator>(begin() + humongousBegin_, end()); in Humongous() 128 return Range<PandaVector<Region *>::iterator>(begin(), begin() + humongousBegin_); in Movable() 133 return Range<PandaVector<Region *>::const_iterator>(begin(), begin() + humongousBegin_); in Movable() [all …]
|
D | g1-allocator.cpp | 55 Region *regWithObj = ObjectToRegion(obj); in IsObjectInYoungSpace() 291 PandaVector<Region *> ObjectAllocatorG1<MT_MODE>::GetYoungRegions() in GetYoungRegions() 297 PandaVector<Region *> ObjectAllocatorG1<MT_MODE>::GetMovableRegions() in GetMovableRegions() 303 PandaVector<Region *> ObjectAllocatorG1<MT_MODE>::GetAllRegions() in GetAllRegions() 305 PandaVector<Region *> regions = objectAllocator_->GetAllRegions(); in GetAllRegions() 306 PandaVector<Region *> nonMovableRegions = nonmovableAllocator_->GetAllRegions(); in GetAllRegions() 307 PandaVector<Region *> humongousRegions = humongousObjectAllocator_->GetAllRegions(); in GetAllRegions() 314 PandaVector<Region *> ObjectAllocatorG1<MT_MODE>::GetNonRegularRegions() in GetNonRegularRegions() 316 PandaVector<Region *> regions = nonmovableAllocator_->GetAllRegions(); in GetNonRegularRegions() 317 PandaVector<Region *> humongousRegions = humongousObjectAllocator_->GetAllRegions(); in GetNonRegularRegions() [all …]
|
/arkcompiler/runtime_core/static_core/runtime/tests/ |
D | collection_set_test.cpp | 60 Region youngRegion(nullptr, 0x0, 0x1000); in TEST_F() 62 PandaVector<Region *> youngRegions = {&youngRegion}; in TEST_F() 78 Region youngRegion(nullptr, 0x0, 0x1000); in TEST_F() 80 PandaVector<Region *> youngRegions = {&youngRegion}; in TEST_F() 81 Region tenuredRegion(nullptr, 0x1000, 0x2000); in TEST_F() 100 Region youngRegion(nullptr, 0x0, 0x1000); in TEST_F() 102 PandaVector<Region *> youngRegions = {&youngRegion}; in TEST_F() 103 Region humongousRegion(nullptr, 0x1000, 0x2000); in TEST_F() 123 Region youngRegion(nullptr, 0x0, 0x1000); in TEST_F() 125 PandaVector<Region *> youngRegions = {&youngRegion}; in TEST_F() [all …]
|
/arkcompiler/ets_runtime/ecmascript/tests/ |
D | read_only_space_test.cpp | 116 auto *region = Region::ObjectAddressToRange(object); in HWTEST_F_L0() 126 auto *regionBefore = Region::ObjectAddressToRange(string.GetObject<TaggedObject>()); in HWTEST_F_L0() 127 auto *objRegionBefore = Region::ObjectAddressToRange(obj.GetObject<TaggedObject>()); in HWTEST_F_L0() 131 auto *regionAfter = Region::ObjectAddressToRange(string.GetObject<TaggedObject>()); in HWTEST_F_L0() 132 auto *objRegionAfter = Region::ObjectAddressToRange(obj.GetObject<TaggedObject>()); in HWTEST_F_L0() 145 auto *region = Region::ObjectAddressToRange(object); in HWTEST_F_L0() 164 auto *region = Region::ObjectAddressToRange(string.GetObject<TaggedObject>()); in HWTEST_F_L0()
|