dotnet / dotnet/docs

Workstation GC for 1 logical CPU

Open
#38,634 4 comments 0 reactions 0 assignees View on GitHub
dotnet-fundamentals/svc waiting-on-feedback
Dominant language
No language data
Stars
4.8k
Forks
6.1k
Avg merge
19h 10m
Merged PRs (30d)
268

Description

### Type of issue

Outdated article

### Description

I'm using .NET8 in GCP Cloud run environment configured with 1 CPU and 512Mo RAM (in order to scale horizontally as needed) and with the CPU throtled when there is no incoming HTTP request

I'm having memory issues that I describe here : https://github.com/googleapis/google-cloud-dotnet/issues/11404

My intuition is that the GC behavior have changed in .NET8 to be Server GC instead of workstattion GC

And so this sentence seems outdated :
> Workstation garbage collection is always used on a computer that has only one logical CPU, regardless of the [configuration setting](https://learn.microsoft.com/en-us/dotnet/core/runtime-config/garbage-collector#workstation-vs-server).

You can see in the linked github issue that with .NET8, the GC is waiting the threshold of 75% to be triggered whereas with .NET6 it was clearing memory more often

### Page URL

https://learn.microsoft.com/en-us/dotnet/standard/garbage-collection/workstation-server-gc#workstation-gc

### Content source URL

https://github.com/dotnet/docs/blob/main/docs/standard/garbage-collection/workstation-server-gc.md

### Document Version Independent Id

a47c1fd9-176e-f6b3-9d87-0b75f8048523

### Article author

@gewarren

### Metadata

* ID: 96231e21-39dd-96c1-8d9a-4155dfe19cec
* Product: **dotnet-fundamentals**

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.