应用程序域和GC堆 [英] AppDomains and GC Heap

查看:111
本文介绍了应用程序域和GC堆的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有单一的GC堆的过程以这样一种方式,每个应用程序域可以访问特定的分区宽分配?或者,每个应用程序域都有独立的GC堆?我相信有关的其他堆如高频堆,低频堆,堆存根,句柄表和几个......,所有这些堆分别分配给每个应用程序域?请问GC堆也被单独分配?

Is there single GC Heap process wide partitioned in such a way that each Application Domain has access to specific partition ? Or each Application Domain has separate GC Heap? I am sure about the other heaps such as HF Heap, LF Heap, Stub Heap, Handle Table and few more..., all these heaps are allocated separately for each application domain? Does the GC Heap also gets allocated separately?

这也许可能是真实的对象不能应用程序域之间传递,除非对象是可序列化或实现为MarshalByRef。我在想,如果有一个与每个对象一种叫AppDomainID关联和对象头(同步块)存储有关AppDomainID的信息?

This may probably be true as objects cannot be passed between AppDomains unless object is serializable or implemented as MarshalByRef. I was thinking if there is something called AppDomainID associated with each object and Object Header (Sync Block) stores the information regarding the AppDomainID?

推荐答案

您已经堆的过程,以及应用程序域共享这个堆。

You have heap for an process, and the app domains share this heap.

应用程序域留轻量的过程,功能单元隔离的过程。

An Application Domain stay light-weight process that functions as unit of isolation in process.

这篇关于应用程序域和GC堆的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆