Skip to content

Fix trim_youngest_desired - #58180

Merged
PeterSolMS merged 1 commit into
dotnet:mainfrom
PeterSolMS:Fix_trim_youngest_desired
Aug 27, 2021
Merged

Fix trim_youngest_desired#58180
PeterSolMS merged 1 commit into
dotnet:mainfrom
PeterSolMS:Fix_trim_youngest_desired

Conversation

@PeterSolMS

Copy link
Copy Markdown
Contributor

The case where we have high memory load and huge main memory can cause the return value to be larger than total_new_allocation.

As it turns out, this is contributing to issue #52592 - gen 0 budget shoots upruptly to 5.1 GB and drops back.

…ain memory - the return value should never be larger than total_new_allocation.
@ghost

Copy link
Copy Markdown

Tagging subscribers to this area: @dotnet/gc
See info in area-owners.md if you want to be subscribed.

Issue Details

The case where we have high memory load and huge main memory can cause the return value to be larger than total_new_allocation.

As it turns out, this is contributing to issue #52592 - gen 0 budget shoots upruptly to 5.1 GB and drops back.

Author:PeterSolMS
Assignees:-
Labels:

area-GC-coreclr

Milestone:-

Comment threadsrc/coreclr/gc/gc.cpp
{
return max (mem_one_percent, total_min_allocation);
size_t total_max_allocation = max (mem_one_percent, total_min_allocation);
return min (total_new_allocation, total_max_allocation);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have we figured out a way to validate such changes? Would the tuning simulator help in such cases?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, I think we should totally add budget calculation to the tuning simulator.

@PeterSolMS
PeterSolMS merged commit 327b9c2 into dotnet:mainAug 27, 2021
@PeterSolMS

Copy link
Copy Markdown
ContributorAuthor

/backport to release/6.0

@github-actions

Copy link
Copy Markdown
Contributor

Started backporting to release/6.0: https://github.com/dotnet/runtime/actions/runs/1193243177

@ghostghost locked as resolved and limited conversation to collaborators Oct 2, 2021
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@PeterSolMS@Maoni0@mangod9