-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
This fixes an issue with gradual decommit in scenarios where we have … #84975
Conversation
…almost exclusively background GCs. The problem is that we turn off the gradual_decommit_in_progress_p flag and rely on the distribute_free_regions flag to turn it back on. If we only trigger a BGC however, distribute_free_regions won't get called and the flag will stay off, despite the global_regions_to_decommit list being non-empty. This will cause regions to accumulate in the global_regions_to_decommit list, and eventual will cause the process to run out of memory.
what if we don't set |
There's a complication in that |
yeh, you could just always reset it during a blocking GC, eg, during the |
…test for the no gc region case in decommit_step.
The better solution appears to be to just test for the no gc region case in decommit_step. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
…almost exclusively background GCs.
The problem is that we turn off the
gradual_decommit_in_progress_p
flag and rely on thedistribute_free_regions
method to turn it back on. If we only trigger a BGC however,distribute_free_regions
won't get called and the flag will stay off, despite theglobal_regions_to_decommit
list being non-empty.This will cause regions to accumulate in the
global_regions_to_decommit
list, and eventual will cause the process to run out of memory.The fix is to remember the setting of the
gradual_decommit_in_progress_p
flag in a local variable and turngradual_decommit_in_progress_p
back on if only a BGC was triggered.This a partial fix to issue #78959.