Andy Wingo
2d1e76eccc
mark-sweep: remote markers can send roots via mark buffers
...
When you have multiple mutators -- perhaps many more than marker threads
-- they can mark their roots in parallel but they can't enqueue them on
the same mark queue concurrently -- mark queues are single-producer,
multiple-consumer queues. Therefore, mutator threads will collect grey
roots from their own root sets, and then send them to the mutator that
is controlling GC, for it to add to the mark queue (somehow).
2022-03-29 15:07:59 +02:00
Andy Wingo
be90f7ba49
mark-sweep: Remove context, use mark space instead
...
This is the end of a series of refactors before adding thread-local
allocation.
2022-03-29 15:07:32 +02:00
Andy Wingo
9b0bc6e975
mark-sweep: Update markers to deal in heap and spaces
...
This will let us get rid of "struct context".
2022-03-29 15:06:28 +02:00
Andy Wingo
2401732e31
mark-sweep: mutator data structure separate from heap
...
This will allow thread-local allocation buffers.
2022-03-29 15:05:59 +02:00
Andy Wingo
61d38e4205
Refactor mark-sweep to send mutator to collect()
...
This will let the mutator hold a pointer to the heap.
2022-03-29 15:05:33 +02:00
Andy Wingo
edd46d8fe2
Start to adapt mark-sweep collector for separate heap/mutator
...
The current hack is that the mutator contains the heap. We'll relax
later on.
2022-03-29 15:04:53 +02:00
Andy Wingo
883a761775
Stub out support for multiple mutator threads on semi, mark-sweep
...
For semi probably we never implement support for multiple mutator
threads. We will do local freelists for mark-sweep though.
2022-03-20 21:03:26 +01:00
Andy Wingo
32ddaa7624
Allocate GC context in GC-managed heap
2022-03-16 21:31:51 +01:00
Andy Wingo
e7a3f83bcc
Add quads benchmark
...
Also expand GC interface with "allocate_pointerless". Limit lazy
sweeping to the allocation size that is causing the sweep, without
adding to fragmentation.
2022-03-16 14:16:22 +01:00
Andy Wingo
a693c4ea8a
Bugfix to mark-sweep
...
Before this, the last sweep would cause premature gc
2022-03-13 21:45:20 +01:00
Andy Wingo
7ce07de670
First crack at parallel marking
2022-03-12 21:09:17 +01:00
Andy Wingo
9c89672c88
Put a local mark queue in front of the work-stealing queue
2022-03-11 11:57:14 +01:00
Andy Wingo
df9edfdff2
Remove tiny objects from mark-sweep
2022-03-11 11:48:26 +01:00
Andy Wingo
f57a1b8a55
Refactor to separate gcbench from gc
2022-03-11 11:48:26 +01:00
Andy Wingo
77ac530360
Add beginnings of parallel marker
2022-03-11 11:48:26 +01:00
Andy Wingo
01d3f9627e
Further accelerate sweeping
2022-03-11 11:48:17 +01:00
Andy Wingo
5edc4fa81a
More efficient sweep
2022-03-11 11:44:11 +01:00
Andy Wingo
5c8a8a2d3e
Store mark bits on the side
...
Lets the sweeper avoid chasing pointers, and is more amenable to
parallel marking.
2022-03-11 11:23:58 +01:00
Andy Wingo
91a330e310
More asserts in mark-sweep
2022-03-11 11:23:58 +01:00
Andy Wingo
c612ff3825
Optimize computation of size class from small object granule count
2022-03-11 11:23:58 +01:00
Andy Wingo
d2828975a5
Switch mark-sweep collector to mark stack
...
Slows down performance though! Have to think here.
2022-03-11 11:23:58 +01:00
Andy Wingo
502c0455a7
Fix mark-sweep allocator to clear contents
2022-03-11 11:23:43 +01:00
Andy Wingo
7b85284a89
Add mark-sweep collector
2022-03-07 10:23:05 +01:00