Android memory analysis: dominator_tree does not show all instances of some objects

I use Eclipse Memory Analyzer to test the behavior MainActivityin my Android application.

I rotated my device exactly 10 times, so I created 11 instances of the class MainActivity.

Looking at the Histogram tab in Eclipse Memory Analyzer, I get this

Histogram

All list objects (right click → lList objects → with incoming links) give me a list of these 11 objects:

List objects with incoming references

so that this is correct, since I have exactly 11 instances of the MainActivity class, as expected (assuming the GC hasn't released these actions yet).

"MainActivity" dominator_tree, 4 ( , ... , , , ):

Dominator_tree

6 ? dominator_tree?

+4
1

, dominator_tree, , :

dominator , GC . ( , " ", " ", " " "

, 6 , Histogram, dominator_tree, ( "" ).

, (, Activity) dominator_tree, ( ) PhantomReference GC .

, dominator_tree:

enter image description here

GC root (pr), , PhantomReference . ( onCreate()):

if(savedInstanceState==null)
    pr = new PhantomReference(this, q); // q is the ReferenceQueue 

, PhantomReference Activity dominator_tree, Reference, GC (Native Stack). :

enter image description here

, Android .

: dominator_tree , GC . .

+1

All Articles