MPS issue job003385

TitlePerformance is poor in large address space on OS X
Statusclosed
Priorityessential
Assigned userRichard Brooksby
OrganizationRavenbrook
DescriptionThis table (taken from [1]) shows the effect of varying the initial allocation of address space to the arena when running the test case "scheme-advanced test-leaf.scm" on platform XCI6LL:

Space Time
1024 42.0
2048 43.2
4096 43.5
8192 46.1
16384 49.2
32768 57.1
65536 71.1
131072 101.3
262144 161.3
524288 273.0
1048576 504.6

"Space" is the initial allocation of address space (in MiB) when calling mps_arena_create. "Time" is the total time taken by the test case in seconds (user+sys).

You'll see that performance gets steadily worse as address space increases (time taken being roughly proportional to the address space).
AnalysisPerhaps the "striping" of address space to make the zones interacts poorly with OS X's multi-level page table? But if that were so, we would expect the time taken to grow like the log of the address space, not linearly with the address space.

Need to check performance on other operating systems before making any changes!

I can't reproduce this behaviour with gcbench on OS X on the 2014-05-17/chunk-tree branch. With seed 10689424:

Size Time
1G 21.7
2G 21.8
4G 21.9
8G 21.7
16G 31.7
32G 31.6
64G 31.7
128G 31.9
256G 32.0
512G 22.1
1024G 22.3

(Interesting step change behaviour there!)
How foundmanual_test
Evidence[1] <https://info.ravenbrook.com/project/mp.../user-guide/manual/html/guide/perf.html>
Observed in1.110.0
Created byGareth Rees
Created on2012-11-16 13:02:26
Last modified byGareth Rees
Last modified on2014-05-22 15:26:06
History2012-11-16 GDR Created.

Fixes

Change Effect Date User Description
184125 closed 2014-01-25 18:00:51 Richard Brooksby Fix broken hysteresis in tract mapping. Only purge spare pages if it’s possible to free a chunk, rather than speculatively every reclaim. See <https://info.ravenbrook.com/mail/2014/01/25/17-37-52/0/>.

Imported from Git
 Author: Richard Brooksby <rb@ravenbrook.com> 1390672851 +0000
 Committer: Richard Brooksby <rb@ravenbrook.com> 1390672851 +0000
 sha1: 75aec80c09e2a623eca13fa0ea14230e438780e9