| 574 | } |
| 575 | |
| 576 | void recomputil_destroy_memory_slotmap(uint8_t* rdram, recomp_context* ctx) { |
| 577 | uint32_t mapkey = _arg<0, uint32_t>(rdram, ctx); |
| 578 | |
| 579 | // Retrieve the map. |
| 580 | MemorySlotmap* map; |
| 581 | if (!memory_slotmaps.get(mapkey, &map)) { |
| 582 | HANDLE_INVALID_ERROR(); |
| 583 | } |
| 584 | |
| 585 | // Free all of the entries in the map. |
| 586 | PTR(void) cur_mem; |
| 587 | while (map->first.erase_first(cur_mem)) { |
| 588 | recomp::free(rdram, TO_PTR(void, cur_mem)); |
| 589 | } |
| 590 | |
| 591 | // Destroy the map itself. |
| 592 | memory_slotmaps.erase(mapkey); |
| 593 | } |
| 594 | |
| 595 | void recomputil_memory_slotmap_contains(uint8_t* rdram, recomp_context* ctx) { |
| 596 | uint32_t mapkey = _arg<0, uint32_t>(rdram, ctx); |
nothing calls this directly
no test coverage detected