Android

Shallow and Retained Size

tomato13 2010. 7. 20. 10:11

http://www.slideshare.net/guest62fd60c/eclipse-memory-analyzer-presentation


Shallow heap is the memory consumed by one object

Retained set of X is the set of objects that will be garbage collected if X is garbage collected.

Retained heap of X is the sum of shallow sizes of all objects in the retained set of X, i.e. memory kept alive by X.


(간단하게 정리해보면 Retained size는 대상 object가 reference하는 object들 모두에 대한 heap size를 가리키고 Shallow size는 대상 object만 한정하여 소요하는 heap size를 가리키는 듯 하다.)