Lookup a memory heap from heap ID
| 415 | |
| 416 | //! Lookup a memory heap from heap ID |
| 417 | static heap_t* |
| 418 | _memory_heap_lookup(int32_t id) { |
| 419 | uint32_t list_idx = id % HEAP_ARRAY_SIZE; |
| 420 | heap_t* heap = atomic_load_ptr(&_memory_heaps[list_idx]); |
| 421 | while (heap && (heap->id != id)) |
| 422 | heap = heap->next_heap; |
| 423 | return heap; |
| 424 | } |
| 425 | |
| 426 | //! Get the span size class from page count |
| 427 | static size_t |
no test coverage detected