0

What does the Unknown -tag mean when you open (Android) heap dump with MAT, go to histogram, the then select e.g. "merge shortest paths..." for your class of interest?

Like here:

 class android.view.inputmethod.InputMethodManager @ 0x40b083f8 Unknown

There can be also other tags like Thread or System class with the Unknown.

I ask this as someone claimed that the Unknowns are subject to GC and could thus be ignored in memory leak analysis. I failed to find a reliable source for this. Can someone verify this?

4

1 回答 1

1

来自MAT 文档

Unknown
未知根类型的对象。某些转储(例如 IBM 便携式堆转储文件)没有根信息。对于这些转储,MAT 解析器将没有入站引用或无法从任何其他根访问的对象标记为这种类型的根。这可确保 MAT 保留转储中的所有对象。

所以我的假设是 Dalvik 没有某些对象的根信息,或者 MAT 不能完全识别 Dalvik 堆。“未知”类型不应该与 GC'ability 相关。

于 2012-07-26T08:10:51.913 回答