[Flashcoders] Memory leaks using XML in Flash Lite 3

2009-08-13 Thread Jim Lafser
I've been fighting memory leaks. I've narrowed it down to use of XML class, but 
only if I actually parse the data. Using onData doesn't leak, onLoad leaks, 
parseXML leaks and new XML(str) leaks.
 
Any Ideas?
 
Thanks



___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Memory Leaks

2007-05-09 Thread Michael Trim
Hi Flashcoders,

What techniques do list members use for tracking down memory leaks in AS2?

It's a problem with repetitive functions called by setInterval events.

It's slow and cumulative but if you leave it on you can see the PF and Mem 
Usage, creep up. 

Can anyone out there share any of their tips, I'm tearing my hair out here, 

Thanks,

Michael




Michael Trim
Senior Producer
Instant Business
a: 8-10 Colston Avenue, 
    Bristol, UK, BS1 4ST
t: +44 (0) 117 915 5175
msn:    [EMAIL PROTECTED]
w:   www.ibltd.com 
 
Company number: 03857884
Registered office: Prospero House
46 -48 Rothesay Road, Luton, Bedfordshire, LU1 1QZ
VAT Registration No. GB 753 1706 40
 
The information in this email is confidential and is intended solely for the 
addressee. Access to this email by anyone else is unauthorised.  If you are not 
the intended recipient, you must not read, use or disseminate the information.  
Any views expressed in this message are those of the individual sender, except 
where the sender specifically states them to be the views of Instant Business 
Ltd.
 
Instant Business servers have scanned this e-mail and any attachments for 
viruses and every reasonable attempt has been made to ensure that it does not 
contain any harmful data.
It is the responsibility of the recipient to ensure that they are virus free 
and no responsibility is accepted by Instant Business Ltd for any loss of data 
or damage caused as a result of opening this message.

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Memory Leaks

2007-05-09 Thread ben gomez farrell
Usually I just track them down, figure out where my setInterval calls 
are and try to plot out in what situations they aren't being cleared.
You could also put some trace calls in the classes or methods you think 
are clearing, and if it stops tracing then you know it's gone from memory.


Additionally you might want to look into better organizing your 
setInterval.  Maybe put them in an array that you can query.  When you 
clear the interval set that index to null.  You could trace the array 
and see all the non-null values.  Maybe you could also make a class to 
manage your setInterval calls better.  A clearAllIntervals method in a 
interval management class could help out a great deal.


I've also had problems before with Delegate memory leaks.  There was a 
great article on Delegate memory management in the last year or so - I 
can't remember where it was, but you can find a similar one here:

http://teknision.blogspot.com/2005/07/delegatesbe-careful.html

ben

Michael Trim wrote:

Hi Flashcoders,

What techniques do list members use for tracking down memory leaks in AS2?

It's a problem with repetitive functions called by setInterval events.

It's slow and cumulative but if you leave it on you can see the PF and Mem Usage, creep up. 

Can anyone out there share any of their tips, I'm tearing my hair out here, 


Thanks,

Michael




Michael Trim
Senior Producer
Instant Business
a: 8-10 Colston Avenue, 
Bristol, UK, BS1 4ST

t: +44 (0) 117 915 5175
msn:[EMAIL PROTECTED]
w:   www.ibltd.com 
 
Company number: 03857884

Registered office: Prospero House
46 -48 Rothesay Road, Luton, Bedfordshire, LU1 1QZ
VAT Registration No. GB 753 1706 40
 
The information in this email is confidential and is intended solely for the addressee. Access to this email by anyone else is unauthorised.  If you are not the intended recipient, you must not read, use or disseminate the information.  Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Instant Business Ltd.
 
Instant Business servers have scanned this e-mail and any attachments for viruses and every reasonable attempt has been made to ensure that it does not contain any harmful data.

It is the responsibility of the recipient to ensure that they are virus free 
and no responsibility is accepted by Instant Business Ltd for any loss of data 
or damage caused as a result of opening this message.

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

  

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Memory Leaks

2007-05-09 Thread Carl Welch

Use while instead of for loop statements. for will eat your resources,
big time.

--Carl

On 5/9/07, ben gomez farrell [EMAIL PROTECTED] wrote:


Usually I just track them down, figure out where my setInterval calls
are and try to plot out in what situations they aren't being cleared.
You could also put some trace calls in the classes or methods you think
are clearing, and if it stops tracing then you know it's gone from memory.

Additionally you might want to look into better organizing your
setInterval.  Maybe put them in an array that you can query.  When you
clear the interval set that index to null.  You could trace the array
and see all the non-null values.  Maybe you could also make a class to
manage your setInterval calls better.  A clearAllIntervals method in a
interval management class could help out a great deal.

I've also had problems before with Delegate memory leaks.  There was a
great article on Delegate memory management in the last year or so - I
can't remember where it was, but you can find a similar one here:
http://teknision.blogspot.com/2005/07/delegatesbe-careful.html

ben

Michael Trim wrote:
 Hi Flashcoders,

 What techniques do list members use for tracking down memory leaks in
AS2?

 It's a problem with repetitive functions called by setInterval events.

 It's slow and cumulative but if you leave it on you can see the PF and
Mem Usage, creep up.

 Can anyone out there share any of their tips, I'm tearing my hair out
here,

 Thanks,

 Michael




 Michael Trim
 Senior Producer
 Instant Business
 a: 8-10 Colston Avenue,
 Bristol, UK, BS1 4ST
 t: +44 (0) 117 915 5175
 msn:[EMAIL PROTECTED]
 w:   www.ibltd.com

 Company number: 03857884
 Registered office: Prospero House
 46 -48 Rothesay Road, Luton, Bedfordshire, LU1 1QZ
 VAT Registration No. GB 753 1706 40

 The information in this email is confidential and is intended solely for
the addressee. Access to this email by anyone else is unauthorised.  If you
are not the intended recipient, you must not read, use or disseminate the
information.  Any views expressed in this message are those of the
individual sender, except where the sender specifically states them to be
the views of Instant Business Ltd.

 Instant Business servers have scanned this e-mail and any attachments
for viruses and every reasonable attempt has been made to ensure that it
does not contain any harmful data.
 It is the responsibility of the recipient to ensure that they are virus
free and no responsibility is accepted by Instant Business Ltd for any loss
of data or damage caused as a result of opening this message.

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com





--
Carl Welch
http://www.carlwelch.com
[EMAIL PROTECTED]
805.403.4819
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Memory Leaks

2007-05-09 Thread Joshua Sera
Look into the BitmapData memory leak issue.

http://www.gskinner.com/blog/archives/2005/10/major_flash_pla.html

Failing that, look for circular references, or unused
objects that you never delete.

--- Michael Trim [EMAIL PROTECTED] wrote:

 Hi Flashcoders,
 
 What techniques do list members use for tracking
 down memory leaks in AS2?
 
 It's a problem with repetitive functions called by
 setInterval events.
 
 It's slow and cumulative but if you leave it on you
 can see the PF and Mem Usage, creep up. 
 
 Can anyone out there share any of their tips, I'm
 tearing my hair out here, 
 
 Thanks,
 
 Michael
 
 
 
 
 Michael Trim
 Senior Producer
 Instant Business
 a: 8-10 Colston Avenue, 
 Bristol, UK, BS1 4ST
 t: +44 (0) 117 915 5175
 msn:[EMAIL PROTECTED]
 w:   www.ibltd.com 
  
 Company number: 03857884
 Registered office: Prospero House
 46 -48 Rothesay Road, Luton, Bedfordshire, LU1 1QZ
 VAT Registration No. GB 753 1706 40
  
 The information in this email is confidential and is
 intended solely for the addressee. Access to this
 email by anyone else is unauthorised.  If you are
 not the intended recipient, you must not read, use
 or disseminate the information.  Any views expressed
 in this message are those of the individual sender,
 except where the sender specifically states them to
 be the views of Instant Business Ltd.
  
 Instant Business servers have scanned this e-mail
 and any attachments for viruses and every reasonable
 attempt has been made to ensure that it does not
 contain any harmful data.
 It is the responsibility of the recipient to ensure
 that they are virus free and no responsibility is
 accepted by Instant Business Ltd for any loss of
 data or damage caused as a result of opening this
 message.
 
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the
 archive:

http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com
 



 

8:00? 8:25? 8:40? Find a flick in no time 
with the Yahoo! Search movie showtime shortcut.
http://tools.search.yahoo.com/shortcuts/#news
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com