When server GC is ignored?

狂风中的少年 提交于 2019-12-13 02:24:54

问题


I found this in the MSDN article about .NET 4 GC : http://msdn.microsoft.com/en-us/library/ee787088.aspx

"Workstation garbage collection is always used on a computer that has only one processor, regardless of the setting. If you specify server garbage collection, the CLR uses workstation garbage collection with concurrency disabled."

I would think that they mean one physical CPU. However I run my app in server GC mode (or at least I thought I did) on a server with one CPU but 8 HT logical processors...

The following code outputs 'true'

        System.Runtime.GCSettings.IsServerGC

So I dont get it - either the following code prints incorrect information or they meant one single core CPU without HT...

Anyone could explain it definitely?


回答1:


it seems the "one processor" refers to a single core no hyper-threading CPU.



来源:https://stackoverflow.com/questions/11488324/when-server-gc-is-ignored

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!