Andy Wingo
053dbf0b61
Pass heap to tracer functions
...
This will allow conservative intra-heap edges. Hopefully no overhead?
2022-10-25 14:25:55 +02:00
Andy Wingo
1e3122d054
trace_worker_steal first does a try_pop on its own deque
...
Before asking other threads for values, see if there is any pending data
that overflowed from the local mark stack.
2022-10-03 15:37:16 +02:00
Andy Wingo
8b8ddaf6e2
work-stealing optimization: stay with last-stolen worker
...
Previously we were always going round-robin. Now a thief tries to
plunder its victim again directly. Should result in less churn.
2022-10-03 15:37:16 +02:00
Andy Wingo
56aad402c9
Fix bug in try_pop on chase-lev deque
...
The counters are unsigned, so that they can overflow. (Is that really
necessary though?) In any case try_pop can decrement a counter, leading
to a situation where you can think you have (size_t)-1 elements; not
good. Instead when computing the queue size, use a signed value.
Limits total queue size to half the unsigned space; fine.
2022-10-03 15:37:16 +02:00
Andy Wingo
f77cf923c1
Fix parallel tracer for gc_ref API change
2022-10-03 15:37:01 +02:00
Andy Wingo
2199d5f48d
Excise struct gcobj
2022-08-16 23:21:16 +02:00
Andy Wingo
6ecf226570
More typesafety, more gc_ref
2022-08-16 22:48:46 +02:00
Andy Wingo
92b8f1e917
Add gc_ prefix to struct heap, struct mutator
2022-08-16 21:35:16 +02:00
Andy Wingo
b082f5f50d
Separate compilation!!!!!
2022-08-16 17:54:15 +02:00
Andy Wingo
fb71c4c363
Separate tagging from collector
...
The collector now has an abstract interface onto the embedder. The
embedder has to supply some functionality, such as tracing and
forwarding. This is a pretty big change in terms of lines but it's
supposed to have no functional or performance change.
2022-08-12 16:44:38 +02:00
Andy Wingo
4ccb489869
Set fixed heap size, parallelism via explicit options
2022-08-09 11:21:02 +02:00
Andy Wingo
2e6dde66b3
Attempt to start creating a proper API
2022-08-09 09:49:51 +02:00
Andy Wingo
e4342f6c45
Add helper for yielding in a spinlock
2022-07-20 14:40:47 +02:00
Andy Wingo
52166fe286
Add gc_edge data structure
...
Less casting in user programs, and it's a step on the way to evacuation
in whippet.
2022-07-20 14:40:47 +02:00
Andy Wingo
119e273fa4
Rename mark-sweep "markers" to "tracers"
...
There could be other reasons than marking to trace the heap.
2022-04-18 15:19:55 +02:00