-
Notifications
You must be signed in to change notification settings - Fork 23.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
defragger improvements around large bins #12963
Comments
This looks like your notes to yourself. :) Do you need the rest of us to get involved? I see #12315. Didn't that already get rid of fragmentation on large bins? |
right, this was a "draft" note in the 8.0 project and i promoted it to an issue so that it can be assigned or discussed. what's fixed in #12315 does reduce some case of "fragmentation" in large bins, but i was worried that it could be others, and wanted to somehow measure only fragmentation inside small bins to trigger defrag. |
@zuiderkwast did you start? if not, i'd like to start. |
@sundb please go ahead! I didn't start. |
@oranagra eliminating large bins actually results in a higher frag rate. |
right. but that's indeed the fragmentation ratio in the area we can defrag. the reason i suggested this change was because i wanted to hide any memory overheads in large bins (or other non-defraggable overheads), i.e. anything that's not defraggable. e.g. we can sum all the memory wasted in small bins (i.e. explicit calculation of small bin fragmentation), and then divide that by the total memory usage, rather than the small-bin memory usage. WDYT? |
@oranagra why is the formula for fragmentation percent |
you mean why isn't it the other difference is that the one in the code measures the fragmentation overhead as a portion of the allocated memory (dividing by am i missing anything? |
Implement #12963 ## Changes 1. large bins don't have external fragmentation or are at least non-defraggable, so we should ignore the effect of large bins when measuring fragmentation, and only measure fragmentation of small bins. this affects both the allocator_frag* metrics and also the active-defrag trigger 2. Adding INFO metrics for `muzzy` memory, which is memory returned to the OS but still shows as RSS until the OS reclaims it. --------- Co-authored-by: Oran Agra <oran@redislabs.com>
jemalloc/jemalloc#1098 (comment)
few things that can be improved:
stats.arenas.<i>.pmuzzy
)The text was updated successfully, but these errors were encountered: