开发者

32 vs 64 bit GC

开发者 https://www.devze.com 2023-02-17 15:02 出处:网络
Does the GC in .NET behave differently in 32 and 64 bit environments? Are there any papers, articles开发者_开发百科 on the same?Garbage collection in 32 and 64 bit programs is similar - there are some

Does the GC in .NET behave differently in 32 and 64 bit environments? Are there any papers, articles开发者_开发百科 on the same?


Garbage collection in 32 and 64 bit programs is similar - there are some differences in how allocation happens and the thresholds the GC uses for analyzing memory pressure - overall, however, the collection model is quite consistent. There are more differences between the client and server implementations of the GC - which you may care about.

In either case, you should try to avoid building programs that rely on specific behavior in the .NET GC. The GC implementation is an internal detail of the .NET runtime, and can change over time - creating systems that expect undocumented or platform-specific behavior from the GC is generally not a good idea and may actually backfire if the algorithms and behavior of the GC changes.

Some articles you may want to read include:

.NET Garbage Collection

How Does the GC Work and the Sizes of Difference Generations

Automatic Memory Management in the .NET Framework

How the CLR Creates Runtime Objects

Low Latency GC in .NET 3.5

Writing High Performance .NET Code

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号