0001-Modify-AllocSetAlloc-not-to-look-at-freelists.patch.txt
text/plain
Filename: 0001-Modify-AllocSetAlloc-not-to-look-at-freelists.patch.txt
Type: text/plain
Part: 2
From 774edcd23cc68b526bbb971db55f6eb30bf8a763 Mon Sep 17 00:00:00 2001
From: David Rowley <dgrowley@gmail.com>
Date: Mon, 25 Mar 2024 22:04:51 +1300
Subject: [PATCH 1/2] Modify AllocSetAlloc not to look at freelists
---
src/backend/utils/mmgr/aset.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/backend/utils/mmgr/aset.c b/src/backend/utils/mmgr/aset.c
index 751cc3408c..c683e2a928 100644
--- a/src/backend/utils/mmgr/aset.c
+++ b/src/backend/utils/mmgr/aset.c
@@ -998,6 +998,7 @@ AllocSetAlloc(MemoryContext context, Size size, int flags)
* doubling the memory requirements for such allocations.
*/
fidx = AllocSetFreeIndex(size);
+#ifdef ALLOCSET_USE_FREELIST
chunk = set->freelist[fidx];
if (chunk != NULL)
{
@@ -1033,6 +1034,7 @@ AllocSetAlloc(MemoryContext context, Size size, int flags)
return MemoryChunkGetPointer(chunk);
}
+#endif
/*
* Choose the actual chunk size to allocate.
--
2.40.1.windows.1