How do you set gcAllowVeryLargeObjects in coreCLR?
Asked Answered
A

1

8

Now that there isn't a app.config, how do you set gcAllowVeryLargeObjects to true so that you can allocate big arrays?

Argyrol answered 23/5, 2016 at 4:26 Comment(0)
C
4

You can use the corresponding environment variable; just remember to use the COMPlus_ prefix (e.g. COMPlus_gcAllowVeryLargeObjects=1).

You can either set this up from the command line before running dotnet run, or add it on the environment variables section of the project's properties within Visual Studio (or probably add a registry entry).

Chaudfroid answered 24/5, 2016 at 20:13 Comment(4)
Link is dead. Are there new instructions some where?Scintilla
Ok this is no longer applicable and set by default.Scintilla
Seems like this does not help HashSet<Int64> to have over 100k entries :(Slander
Link in answer is dead - "404 | Page not found". See github.com/dotnet/coreclr/pull/27612 and also learn.microsoft.com/en-us/dotnet/core/run-time-config/…Dulaney

© 2022 - 2024 — McMap. All rights reserved.