Switch sorted list of pages in the GC to a darray

This commit is contained in:
Peter Zhu 2024-09-04 11:59:37 -04:00
parent 16f241f0aa
commit b66d6e48c8
3 changed files with 78 additions and 138 deletions

View file

@ -208,7 +208,6 @@ class TestGc < Test::Unit::TestCase
# marking_time + sweeping_time could differ from time by 1 because they're stored in nanoseconds
assert_in_delta stat[:time], stat[:marking_time] + stat[:sweeping_time], 1
assert_equal stat[:total_allocated_pages], stat[:heap_allocated_pages] + stat[:total_freed_pages]
assert_operator stat[:heap_sorted_length], :>=, stat[:heap_eden_pages] + stat[:heap_allocatable_pages], "stat is: " + stat.inspect
assert_equal stat[:heap_available_slots], stat[:heap_live_slots] + stat[:heap_free_slots] + stat[:heap_final_slots]
assert_equal stat[:heap_live_slots], stat[:total_allocated_objects] - stat[:total_freed_objects] - stat[:heap_final_slots]
assert_equal stat[:heap_allocated_pages], stat[:heap_eden_pages] + stat[:heap_tomb_pages]