[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#28590: [PATCH 2/7] weak-table: Stress the GC a little less when resi
From: |
Ludovic Courtès |
Subject: |
bug#28590: [PATCH 2/7] weak-table: Stress the GC a little less when resizing. |
Date: |
Tue, 3 Oct 2017 13:43:47 +0200 |
* libguile/weak-table.c (resize_table): Move 'allocate_entries' call
outside of the loop.
---
libguile/weak-table.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libguile/weak-table.c b/libguile/weak-table.c
index a0bebca5e..1aa2a0fcc 100644
--- a/libguile/weak-table.c
+++ b/libguile/weak-table.c
@@ -476,10 +476,11 @@ resize_table (scm_t_weak_table *table)
if (new_size_index == table->size_index)
return;
new_size = hashtable_size[new_size_index];
- new_entries = allocate_entries (new_size, table->kind);
}
while (!is_acceptable_size_index (table, new_size_index));
+ new_entries = allocate_entries (new_size, table->kind);
+
old_entries = table->entries;
old_size = table->size;
--
2.14.2
- bug#28590: [PATCH 0/7] Attempt to reduce memory growth, Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 6/7] weak-table: 'rob_from_rich' accounts for disappeared entries., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 7/7] weak-table: Resize less frequently., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 3/7] weak-table: Make sure 'move_disappearing_links' actually moves links., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 2/7] weak-table: Stress the GC a little less when resizing.,
Ludovic Courtès <=
- bug#28590: [PATCH 1/7] weak-table: Fix unbounded growth of the disappearing link table., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 5/7] weak-table: 'move_weak_entry' reports disappeared links., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 4/7] weak-table: Always unregister previous links when inserting an entry., Ludovic Courtès, 2017/10/03
- bug#28590: [PATCH 0/7] Attempt to reduce memory growth, Ludovic Courtès, 2017/10/04