android-developers
[Arriba] [Todas las Listas]

[android-developers] Tracking Abajo casos de Actividad múltiple en memo

To: android-developers@xxxxxxxxxxxxxxxx
Subject: [android-developers] Tracking Abajo casos de Actividad múltiple en memoria
From: Nathan <nathan.d.mellor@xxxxxxxxx>
Date: Tue, 9 Sep 2014 21:00:36 -0700 (PDT)
Delivery-date: Wed, 10 Sep 2014 00:02:00 -0400
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=date:from:to:message-id:subject:mime-version:x-original-sender :reply-to:precedence:mailing-list:list-id:list-post:list-help :list-archive:sender:list-subscribe:list-unsubscribe:content-type; bh=uaSe6/1cT2EiP8s92+Lh1gwlXHTnK6Qbdx+fyuQ74Nw=; b=bHdbr4YhBISwBZ9eit46t/42lzxcjc3OM8ML3fTOrUYrjDjwOtpJ1nM+/Ilthhx7fm bR51s6HMT7jUKpuojxp8AOi0Ozpa43gB0YmhGuWBUUMHqnFgVsUD9NNCbi2hlg4kg7KW fHuYExfVXFMAYeoETIZo3mFoiHT30EVd7kdllfPfHPgUO3e5s3fDGREaMrzkZ8/4WjTi ZfFPj1DDP49x4w1PPw6X/o/RXcHJmNYqlLkqMN1FGBbjPUR1+GRwV7bS3WQgvI4OBjTV tNfVAFCCLrl4PaI0O45KPCZ9oFUSHQFleD9dSP3RCwjsD8isRovc+hxK8H9wmI7jLPtX +LEA==
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:message-id:subject:mime-version:x-original-sender :reply-to:precedence:mailing-list:list-id:list-post:list-help :list-archive:sender:list-subscribe:list-unsubscribe:content-type; bh=uaSe6/1cT2EiP8s92+Lh1gwlXHTnK6Qbdx+fyuQ74Nw=; b=SArn3vd5t7DAw+VrT3jZRdHp7Ws4qI6P1Yb611S3annxhbcl8ricPhxPURbY5rJdfQ DAwdEzzRAiY767XgdSowmVmGB2W4wYQZ07UTtOYA3GDhqYSf2PXJ5NWfbAxS+NllNLvd 7m9GzkF6WDGc0jEohxvgo4TenEELnWz+7meHMOhQVOesoYchWSsE/6bvpqPffpqtLxQK yBQ5uSm0RwH+88G51zXzXTZK2qG6IssURDNFoqZIJtCu3l3K8FZWkzVFscgeOclYNd7o j1yVvr1Uc4ichh/mCCDucnm7LsxVSK7D0RPG5D2guPx7zz3kywHkltQWY5wbpIE9on7H MyAg==
Envelope-to: traductor@xxxxxxxxxxx
List-archive: <http://groups.google.com/group/android-developer>
List-help: <http://groups.google.com/support/>, <mailto:android-developers+help@googlegroups.com>
List-id: <android-developers.googlegroups.com>
List-post: <http://groups.google.com/group/android-developers/post>, <mailto:android-developers@googlegroups.com>
List-subscribe: <http://groups.google.com/group/android-developers/subscribe>, <mailto:android-developers+subscribe@googlegroups.com>
List-unsubscribe: <mailto:googlegroups-manage+364598216046+unsubscribe@googlegroups.com>, <http://groups.google.com/group/android-developers/subscribe>
Mailing-list: list android-developers@xxxxxxxxxxxxxxxx; contact android-developers+owners@xxxxxxxxxxxxxxxx
Reply-to: android-developers@xxxxxxxxxxxxxxxx
Sender: android-developers@xxxxxxxxxxxxxxxx
Soy *fairly seguro he sido capaz de utilizar el *eclipse herramientas antes de que a pista 
abajo filtraciones de memoria - yo incluso encontrado uno en *Google *Analytics. 

Pero puedo no para la vida de mí imagina fuera.

He descubierto que hay dos casos de Actividad *B en memoria cuándo 
la actividad es cerrada. Puedo ver que con sé 

bastante para saber que aquello es mal. 

Pero lo que no puedo ver es POR QUÉ. Por qué es que actividad estúpida todavía en memoria 
dos veces?

Parezco para recordar que yo bien clic en algo y escoger Fusionar Camino a Raíces 
de GC. 

Entonces consigo algo así. 


Nombre 
de clase                                                                                       
| *Ref. Los Objetos | Superficiales *Heap | *Ref. Superficial *Heap | Retuvo *Heap
-------------------------------------------------------------------------------------------------------------------------------------------------------------------
*com.*android.Interno.Política.*impl.*PhoneLayoutInflater @ 0*x42*d2*b0*d8 
*Unknown                        |            1 |           40 
|               536 |            64
'- *mPrivateFactory, *mContext *MyActivity @ 0*x42*d28230|            1 
|          536 |               536 |       127,336
clase *com.*android.Interno.*os.*ZygoteInit @ 0*x41#uno21una18 Clase 
de Sistema                               |            1 |          120 
|               536 |         1,000
'- *mResources *android.Contenido.*res.Recursos @ 
0*x41*aa7108                                         |            1 
|          112 |               536 |         8,512
   '- *mContext *android.*app.*ContextImpl @ 
0*x43009398                                              |            1 
|          128 |               536 |        10,400
      '- *mOuterContext *MyActivity @ 0*x42*d4*f008      |            1 
|          536 |               536 |         3,864
-------------------------------------------------------------------------------------------------------------------------------------------------------------------

Bien que *PhoneLayoutInflater no tendría que ser aguantando encima a aquel contexto de una 
actividad cerrada, pero no pienso controlo aquello. 
Y sin duda que *ZygoteInit la cosa no tendría que ser aguantando un contexto en 
un *static manera, pero no controlo que cualquiera. 

Cualesquier consejos en encontrar las causas mejores?

Nathan


Nathan

-- 
recibiste este mensaje porque eres *subscribed al *Google
Grupos "*Android *Developers" grupo.
A correo a este grupo, envía *email a *android-developers@xxxxxxxxxxxxxxxx
A *unsubscribe de este grupo, envía *email a *android-*developers+unsubscribe@xxxxxxxxxxxxxxxx

Puesto que más opciones, visita este grupo en
*http://grupos.*google.*com/Grupo/*android-*developers?*hl=*en
--- 
Recibiste este mensaje porque eres *subscribed al *Google Grupos "*Android *Developers" grupo.
A *unsubscribe de este grupo y la parón que recibe *emails de él, enviar un *email a *android-*developers+unsubscribe@xxxxxxxxxxxxxxxx.
Puesto que más opciones, visita *https://grupos.*google.*com/*d/*optout.
I'm fairly sure I have been able to use the eclipse tools before to track 
down memory leaks - I even found one in Google Analytics. 

But I can't for the life of me figure out.

I have found out that there are two instances of Activity B in memory when 
the activity is closed. I can see that with 

I know enough to know that that is bad. 

But what I cannot see is WHY. Why is that stupid activity still in memory 
twice?

I seem to remember that I right click on something and choose Merge Path to 
GC Roots. 

Then I get something like this. 


Class 
Name                                                                                       
| Ref. Objects | Shallow Heap | Ref. Shallow Heap | Retained Heap
-------------------------------------------------------------------------------------------------------------------------------------------------------------------
com.android.internal.policy.impl.PhoneLayoutInflater @ 0x42d2b0d8 
Unknown                        |            1 |           40 
|               536 |            64
'- mPrivateFactory, mContext MyActivity @ 0x42d28230|            1 
|          536 |               536 |       127,336
class com.android.internal.os.ZygoteInit @ 0x41a21a18 System 
Class                               |            1 |          120 
|               536 |         1,000
'- mResources android.content.res.Resources @ 
0x41aa7108                                         |            1 
|          112 |               536 |         8,512
   '- mContext android.app.ContextImpl @ 
0x43009398                                              |            1 
|          128 |               536 |        10,400
      '- mOuterContext MyActivity @ 0x42d4f008      |            1 
|          536 |               536 |         3,864
-------------------------------------------------------------------------------------------------------------------------------------------------------------------

Well that PhoneLayoutInflater shouldn't be holding on to that context of a 
closed activity, but I don't think I control that. 
And definitely that ZygoteInit thing shouldn't be holding a context in a 
static way, but I don't control that either. 

Any tips on finding the causes better?

Nathan


Nathan

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@xxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
android-developers+unsubscribe@xxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups "Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@xxxxxxxxxxxxxxxx.
For more options, visit https://groups.google.com/d/optout.
<Anterior por Tema] Tema Actual [Siguiente por Tema>