[compiler-rt] [scudo] Don't preserve space for regions at init() (DO NOT MERGE) (PR #74531)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 11 13:38:44 PST 2023
================
@@ -982,6 +999,21 @@ template <typename Config> class SizeClassAllocator64 {
const uptr Size = getSizeByClassId(ClassId);
const u16 MaxCount = CacheT::getMaxCached(Size);
+ MemMapT &RegionMemMap = Region->MemMapInfo.MemMap;
+ if (UNLIKELY(!RegionMemMap.isAllocated())) {
+ DCHECK_EQ(Region->RegionBeg, 0U);
+ ReservedMemoryT ReservedMemory;
+ ReservedMemory.create(/*Addr=*/0U, RegionSize, "scudo:primary_reserve");
----------------
ChiaHungDuan wrote:
Done. BTW, I did `push -f` to avoid having to cherry-pick all fix-ups.
https://github.com/llvm/llvm-project/pull/74531
More information about the llvm-commits
mailing list