mirror of
https://github.com/ruby/ruby.git
synced 2026-01-27 04:24:23 +00:00
[ruby/mmtk] Make rb_gc_impl_heap_id_for_size use MMTK_HEAP_COUNT
https://github.com/ruby/mmtk/commit/2185189df4
This commit is contained in:
parent
fe9a7448b1
commit
6d5605b28a
@ -657,7 +657,7 @@ rb_gc_impl_obj_slot_size(VALUE obj)
|
||||
size_t
|
||||
rb_gc_impl_heap_id_for_size(void *objspace_ptr, size_t size)
|
||||
{
|
||||
for (int i = 0; i < 5; i++) {
|
||||
for (int i = 0; i < MMTK_HEAP_COUNT; i++) {
|
||||
if (size == heap_sizes[i]) return i;
|
||||
if (size < heap_sizes[i]) return i;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user