Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Commit

Permalink
Merge pull request #826 from etcimon/gc_exp_newPool
Browse files Browse the repository at this point in the history
Exponential policy for new pool size
  • Loading branch information
andralex committed Sep 23, 2014
2 parents 05c9db3 + 548f3e2 commit 82a59ce
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/gc/gc.d
Original file line number Diff line number Diff line change
Expand Up @@ -2226,11 +2226,8 @@ struct Gcx
if (npools)
{ size_t n;

n = npools;
if (n > 32)
n = 32; // cap pool size at 32 megs
else if (n > 8)
n = 16;
n = npools * 3;

n *= (POOLSIZE / PAGESIZE);
if (npages < n)
npages = n;
Expand Down

0 comments on commit 82a59ce

Please sign in to comment.