We've recently implemented a garbage collector for Plush (#25), but it seems to perform much worse than I would have expected as the number of objects increases.
For example, if you run this benchmark, which allocates a linked list with 1 million nodes and then runs multiple GC cycles in a loop:
cargo run benchmarks/gc_many_objs.psh
The last GC cycle takes ~219 ms for ~1M values. Unfortunately 1 million objects is really not that many. I would have expected this to be able to run in less than 50 milliseconds. The GC performance means that we could get noticeable pauses if there's about 250K+ allocated objects.
We probably need to profile this test and try to determine where the overhead is coming from, or if there's a performance bug.
We've recently implemented a garbage collector for Plush (#25), but it seems to perform much worse than I would have expected as the number of objects increases.
For example, if you run this benchmark, which allocates a linked list with 1 million nodes and then runs multiple GC cycles in a loop:
The last GC cycle takes ~219 ms for ~1M values. Unfortunately 1 million objects is really not that many. I would have expected this to be able to run in less than 50 milliseconds. The GC performance means that we could get noticeable pauses if there's about 250K+ allocated objects.
We probably need to profile this test and try to determine where the overhead is coming from, or if there's a performance bug.