[MLton-commit] r6779

Matthew Fluet fluet at mlton.org
Tue Aug 19 17:44:03 PDT 2008


Backoffs rarely succeed; power of 2 seems nicer
----------------------------------------------------------------------

U   mlton/trunk/runtime/gc/heap.c

----------------------------------------------------------------------

Modified: mlton/trunk/runtime/gc/heap.c
===================================================================
--- mlton/trunk/runtime/gc/heap.c	2008-08-20 00:43:58 UTC (rev 6778)
+++ mlton/trunk/runtime/gc/heap.c	2008-08-20 00:44:02 UTC (rev 6779)
@@ -170,7 +170,7 @@
   minSize = align (minSize, s->sysvals.pageSize);
   desiredSize = align (desiredSize, s->sysvals.pageSize);
   assert (0 == h->size and NULL == h->start);
-  backoff = (desiredSize - minSize) / 20;
+  backoff = (desiredSize - minSize) / 16;
   if (0 == backoff)
     backoff = 1; /* enough to terminate the loop below */
   backoff = align (backoff, s->sysvals.pageSize);
@@ -277,7 +277,7 @@
   assert (desiredSize >= h->size);
   minSize = align (minSize, s->sysvals.pageSize);
   desiredSize = align (desiredSize, s->sysvals.pageSize);
-  backoff = (desiredSize - minSize) / 20;
+  backoff = (desiredSize - minSize) / 16;
   if (0 == backoff)
     backoff = 1; /* enough to terminate the loop below */
   backoff = align (backoff, s->sysvals.pageSize);




More information about the MLton-commit mailing list