/arkcompiler/runtime_core/libpandabase/mem/ |
H A D | mem.h | 192 constexpr size_t PANDA_POOL_ALIGNMENT_IN_BYTES = 256_KB; member 197 static_assert(PANDA_DEFAULT_POOL_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 198 static_assert(PANDA_DEFAULT_ARENA_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 199 static_assert(PANDA_DEFAULT_ALLOCATOR_POOL_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 203 constexpr uintptr_t PANDA_32BITS_HEAP_START_ADDRESS = AlignUp(1U, PANDA_POOL_ALIGNMENT_IN_BYTES);
|
H A D | mmap_mem_pool-inl.h | 134 // We should get aligned to PANDA_POOL_ALIGNMENT_IN_BYTES size in MmapMemPool() 135 void *mem = panda::os::mem::MapRWAnonymousWithAlignmentRaw(object_space_size, PANDA_POOL_ALIGNMENT_IN_BYTES); in MmapMemPool() 139 ASSERT(AlignUp(ToUintPtr(mem), PANDA_POOL_ALIGNMENT_IN_BYTES) == ToUintPtr(mem)); in MmapMemPool() 218 mem = panda::os::mem::MapRWAnonymousWithAlignmentRaw(size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AllocRawMemCompilerImpl() 232 mem = panda::os::mem::MapRWAnonymousWithAlignmentRaw(size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AllocRawMemInternalImpl() 246 mem = panda::os::mem::MapRWAnonymousWithAlignmentRaw(size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AllocRawMemCodeImpl() 269 // which require PANDA_POOL_ALIGNMENT_IN_BYTES alignment in AllocRawMemImpl() 270 ASSERT(size == AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES)); in AllocRawMemImpl() 316 ASSERT(size == AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES)); in AllocPoolUnsafe() 361 ASSERT(AlignUp(ToUintPtr(pool.GetMem()), PANDA_POOL_ALIGNMENT_IN_BYTES) in AllocPoolUnsafe() [all...] |
H A D | pool_map.h | 90 static constexpr size_t POOL_MAP_GRANULARITY = PANDA_POOL_ALIGNMENT_IN_BYTES;
|
H A D | arena_allocator.cpp | 157 pool_size = AlignUp(pool_size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AddArenaFromPool()
|
/arkcompiler/runtime_core/static_core/libpandabase/mem/ |
H A D | mem.h | 218 constexpr size_t PANDA_POOL_ALIGNMENT_IN_BYTES = 256_KB; member 223 static_assert(PANDA_DEFAULT_POOL_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 224 static_assert(PANDA_DEFAULT_ARENA_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 225 static_assert(PANDA_DEFAULT_ALLOCATOR_POOL_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0); 229 constexpr uintptr_t PANDA_32BITS_HEAP_START_ADDRESS = AlignUp(1U, PANDA_POOL_ALIGNMENT_IN_BYTES);
|
H A D | mmap_mem_pool-inl.h | 173 // Object space must be aligned to PANDA_POOL_ALIGNMENT_IN_BYTES 174 PANDA_POOL_ALIGNMENT_IN_BYTES); 178 // We should get aligned to PANDA_POOL_ALIGNMENT_IN_BYTES size 179 void *mem = ark::os::mem::MapRWAnonymousWithAlignmentRaw(objectSpaceSize, PANDA_POOL_ALIGNMENT_IN_BYTES); 183 ASSERT(AlignUp(ToUintPtr(mem), PANDA_POOL_ALIGNMENT_IN_BYTES) == ToUintPtr(mem)); 315 mem = ark::os::mem::MapRWAnonymousWithAlignmentRaw(size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AllocRawMemNonObjectImpl() 341 // which require PANDA_POOL_ALIGNMENT_IN_BYTES alignment in AllocRawMemImpl() 342 ASSERT(size == AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES)); in AllocRawMemImpl() 388 ASSERT(size == AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES)); in AllocPoolUnsafe() 441 ASSERT(AlignUp(ToUintPtr(pool.GetMem()), PANDA_POOL_ALIGNMENT_IN_BYTES) in AllocPoolUnsafe() [all...] |
H A D | pool_map.h | 92 static_assert(PANDA_POOL_ALIGNMENT_IN_BYTES == 1U << POOL_MAP_GRANULARITY_SHIFT);
|
H A D | arena_allocator.cpp | 152 poolSize = AlignUp(poolSize, PANDA_POOL_ALIGNMENT_IN_BYTES); in AddArenaFromPool()
|
/arkcompiler/runtime_core/static_core/runtime/tests/ |
H A D | crossing_map_test.cpp | 303 void *startAddr = GetRandomObjAddr((POOLS_SIZE * 2U + PANDA_POOL_ALIGNMENT_IN_BYTES) * POOL_COUNT + in TEST_F() 304 PANDA_POOL_ALIGNMENT_IN_BYTES); in TEST_F() 305 uintptr_t alignedStartAddr = AlignUp(ToUintPtr(startAddr), PANDA_POOL_ALIGNMENT_IN_BYTES); in TEST_F() 309 void *poolAddr = ToVoidPtr(alignedStartAddr + i * (POOLS_SIZE * 2U + PANDA_POOL_ALIGNMENT_IN_BYTES)); in TEST_F() 315 void *poolAddr = ToVoidPtr(alignedStartAddr + i * (POOLS_SIZE * 2U + PANDA_POOL_ALIGNMENT_IN_BYTES)); in TEST_F() 324 void *poolAddr = ToVoidPtr(alignedStartAddr + i * (POOLS_SIZE * 2U + PANDA_POOL_ALIGNMENT_IN_BYTES)); in TEST_F()
|
H A D | humongous_obj_allocator_test.cpp | 68 size = AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES); in AddMemoryPoolToAllocator() 69 Pool pool = PoolManager::GetMmapMemPool()->AllocPool(AlignUp(size, PANDA_POOL_ALIGNMENT_IN_BYTES), in AddMemoryPoolToAllocator() 111 static constexpr size_t FIRST_OBJECT_SIZE = POOL_SIZE - PANDA_POOL_ALIGNMENT_IN_BYTES; in TEST_F() 113 ASSERT(PANDA_POOL_ALIGNMENT_IN_BYTES > GetAlignmentInBytes(OBJECT_ALIGNMENT)); in TEST_F()
|
/arkcompiler/runtime_core/libpandabase/tests/ |
H A D | pool_map_test.cpp | 44 static constexpr size_t MINIMAL_POOL_SIZE = PANDA_POOL_ALIGNMENT_IN_BYTES; 172 static constexpr uintptr_t POOL_START_ADDR = PANDA_POOL_ALIGNMENT_IN_BYTES; in HWTEST_F() 174 size_t pool_size = AlignUp(rand() % MAX_POOL_SIZE, PANDA_POOL_ALIGNMENT_IN_BYTES); in HWTEST_F()
|
/arkcompiler/runtime_core/static_core/libpandabase/tests/ |
H A D | pool_map_test.cpp | 48 static constexpr size_t MINIMAL_POOL_SIZE = PANDA_POOL_ALIGNMENT_IN_BYTES; 178 static constexpr uintptr_t POOL_START_ADDR = PANDA_POOL_ALIGNMENT_IN_BYTES; in TEST_F() 181 size_t poolSize = AlignUp(rand() % MAX_POOL_SIZE, PANDA_POOL_ALIGNMENT_IN_BYTES); in TEST_F()
|
/arkcompiler/ets_runtime/ecmascript/mem/ |
H A D | heap_region_allocator.cpp | 22 constexpr size_t PANDA_POOL_ALIGNMENT_IN_BYTES = 256_KB; member 64 LOG_ECMA_IF(AlignUp(mem, PANDA_POOL_ALIGNMENT_IN_BYTES) != mem, FATAL) << "region not align by 256KB"; in AllocateAlignedRegion()
|
H A D | space.cpp | 151 size_t allocSize = AlignUp(mutableSize + desc->instructionsSize, PANDA_POOL_ALIGNMENT_IN_BYTES); in AllocateFort() 223 size_t alignedSize = AlignUp(objectSize + sizeof(Region) + HUGE_OBJECT_BITSET_SIZE, PANDA_POOL_ALIGNMENT_IN_BYTES); in Allocate()
|
H A D | linear_space.cpp | 262 LOG_ECMA_IF(AlignUp(mem, PANDA_POOL_ALIGNMENT_IN_BYTES) != mem, FATAL) << "region not align by 256KB"; in AllocRegion()
|
/arkcompiler/runtime_core/static_core/runtime/mem/ |
H A D | frame_allocator.h | 77 static_assert(FIRST_ARENA_SIZE % PANDA_POOL_ALIGNMENT_IN_BYTES == 0);
|
H A D | humongous_obj_allocator.h | 144 PANDA_POOL_ALIGNMENT_IN_BYTES); in GetMinPoolSize()
|
H A D | heap_space.cpp | 148 AlignUp(memSpace_.GetCurrentSize() + PANDA_DEFAULT_POOL_SIZE, PANDA_POOL_ALIGNMENT_IN_BYTES)); in ClampCurrentMaxHeapSize()
|
H A D | region_allocator.h | 661 static_assert(REGION_SIZE / PANDA_POOL_ALIGNMENT_IN_BYTES == 1);
|
/arkcompiler/runtime_core/static_core/runtime/mem/gc/heap-space-misc/ |
H A D | crossing_map.h | 128 static constexpr size_t CROSSING_MAP_STATIC_ARRAY_GRANULARITY = PANDA_POOL_ALIGNMENT_IN_BYTES;
|
/arkcompiler/runtime_core/static_core/runtime/ |
H A D | runtime.cpp | 299 std::max(AlignDown(initialObjectSize, PANDA_POOL_ALIGNMENT_IN_BYTES), PANDA_POOL_ALIGNMENT_IN_BYTES); in CreateMemorySpaces() 300 maxObjectSize = std::max(AlignDown(maxObjectSize, PANDA_POOL_ALIGNMENT_IN_BYTES), PANDA_POOL_ALIGNMENT_IN_BYTES); in CreateMemorySpaces()
|
/arkcompiler/runtime_core/static_core/runtime/coroutines/ |
H A D | stackful_coroutine_manager.cpp | 122 if (coroStackSizeBytes_ != AlignUp(coroStackSizeBytes_, PANDA_POOL_ALIGNMENT_IN_BYTES)) { in Initialize() 123 size_t alignmentPages = PANDA_POOL_ALIGNMENT_IN_BYTES / os::mem::GetPageSize(); in Initialize()
|
/arkcompiler/ets_runtime/ecmascript/mem/shared_heap/ |
H A D | shared_space.cpp | 599 size_t alignedSize = AlignUp(objectSize + sizeof(Region) + HUGE_OBJECT_BITSET_SIZE, PANDA_POOL_ALIGNMENT_IN_BYTES); in Allocate()
|
/arkcompiler/ets_runtime/ecmascript/snapshot/mem/ |
H A D | snapshot_processor.cpp | 1273 size_t alignedHugeRegionSize = AlignUp(objSize + hugeRegionHeadSize, PANDA_POOL_ALIGNMENT_IN_BYTES); in DeserializeHugeSpaceObject()
|