| 821 | } |
| 822 | |
| 823 | static size_t |
| 824 | arena_stash_decayed(tsdn_t *tsdn, arena_t *arena, |
| 825 | extent_hooks_t **r_extent_hooks, extents_t *extents, size_t npages_limit, |
| 826 | size_t npages_decay_max, extent_list_t *decay_extents) { |
| 827 | witness_assert_depth_to_rank(tsdn_witness_tsdp_get(tsdn), |
| 828 | WITNESS_RANK_CORE, 0); |
| 829 | |
| 830 | /* Stash extents according to npages_limit. */ |
| 831 | size_t nstashed = 0; |
| 832 | extent_t *extent; |
| 833 | while (nstashed < npages_decay_max && |
| 834 | (extent = extents_evict(tsdn, arena, r_extent_hooks, extents, |
| 835 | npages_limit)) != NULL) { |
| 836 | extent_list_append(decay_extents, extent); |
| 837 | nstashed += extent_size_get(extent) >> LG_PAGE; |
| 838 | } |
| 839 | return nstashed; |
| 840 | } |
| 841 | |
| 842 | static size_t |
| 843 | arena_decay_stashed(tsdn_t *tsdn, arena_t *arena, |
no test coverage detected