Memory Leak in .swf

Memory Leak issue with CS4
Using CS4, we have a memory leak and I can not find the
source of the problem.
http://tiny.cc/O7D3e here is the
link to the testing site. If you take a look at your task manager
you will see it your RAM will continue to increase even after two
or three cycles. It does not stabilize.
We are using FlashEff | Flash Effects Component in order to
generate the smooth transitions. However, I have done some
debugging and even completely deleted the plug n from the file and
it still continually leaks memory. Does anyone have any possible
solutions or causes for this.

One idea - there is a separate stack of memory in the flash
player where loaded classes in separate application domains exist,
and these classes are not being garbage collected....however, there
is a line in adobe's documentation here:
http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=Liv eDocs_Parts&file=00000327.html
under "Usage C" :
quote:
Having a new application domain also allows you to unload all
the class definitions for garbage collection, if you can ensure
that you do not continue to have references to the child SWF.
Given that, as far as I can see from this code, there is no
reference to the loaded .swf maintained....it seems to me like the
loaded data (graphical assets AND classes) should be garbage
collected - but, while you WILL see a slight drop in memory after
the removal of the SWF, the overall memory continues to increase
the more you do it. Could Adobe be mistaken?

Similar Messages

  • Memory leak with swf generated by Xcelsius 4.5?

    Hello,
    I've experienced some memory problems with swf generated with Xcelsius 4.5. I'm using Windows Vista and Internet Explorer 7.
    I noticed that every time I refresh my dashboard using the F5 key, the memory used by the Internet Explorer process increases (or doubles).So, in case I need to refresh my dashboard many times, the memory used by the browser becomes definitely too much and compromises my system stability.
    Does anyone have experienced this problem? Is this a memory leak? Is there a way to fix this problem?
    Thank you,

    That's the trick who does it, thank you!

  • Adobe AIR memory leak loading SWFs

    I was plagued by a memory leak that would crash my application after a few hours. The application had worked fine in the past but now was having issues and I thought it might have to do with using newer SDK's.
    In the end I discovered that if I loaded external swf that had been compiled in debug mode, they would not clear completely on unload and cause a memory leak.
    Compiling in release mode fixed the issue. Spent 3 days trying to figure it out.

    Any chance you can check that out with the latest AIR?
    Either way, it sounds like a bug, please report it at http://bugbase.adobe.com/ and then report the bug number here. 
    If you're able to provide a reproducable case that would really increase the chance that we can do something about it.
    Thanks,
    roymeo

  • Memory leak in Flash with Win7, IE9, 64bit

    I have been having an issue for quite some time on 2 different computers. Both of them are Windows 7 64bit and use IE9.
    Generally I have 1 - 5 tabs open in IE at any given time. Usually one of them is a tab for Yahoo Mail. Other tabs are related to whatever I may be searching for or doing at that time, so pretty varied. Throughout the day at random times I will begin to get a grey icon for anywhere on some tabs where there is supposed to be a flash video (like the ad in the right side of the Yahoo Mail tab)... When it happens I can open Task Manager in windows and I notice that 1 or two "iexplore.exe *32" processes have memory consumed in excess of 600,000K. When I end those processes I am again able to see any flash videos that need to be viewed.
    If I leave Task Manager open throughout the day I can see the memory consumption increase on various tabs until I cannot see any more flash videos or even open new tabs in IE until I end those processes. Further, the memory does not get released if I just close the tabs in IE, but I must either end the specific process or close all tabs in IE so that IE is completely unloaded.
    I have since uninstalled the Flash player and the issue has gone away. I can re-install the flash player and the issue returns. Can you please help? This has been a huge annoyance and I had hoped that it would be fixed sooner or later. Unfortunately it has not been fixed and has finally prompted me to post something....

    First, I just wanted to follow up on this thread and let you guys know that we'll continue to look into it.  I also want to clarify some player behavior, and provide tips for helping to identify a defect that we can take action on.
    Whenever you refresh/reload a tab, the browser should signal to us that our process is being destroyed, at which point we would release all of our resources and shut down.  SergeStone's comment above makes it sound like this might not be happening in a particular case.  I'm going to build out a few tests this week to explore this in more detail, and I'll follow up with results.
    Also, it's worth discussing the difference between memory consumption and memory leaks.  Flash Player is designed to consume a percentage of your available memory.  If you have a 32-bit machine with 2GB of RAM, we're going to consume a lot less memory than a 64-bit system with 16GB of RAM. 
    Not all Flash content is authored well.  If the ActionScript developer is continuously loading objects into their SWF and never releasing them (a slide-show is a good simplistic example), you'll see a steady usage increase as each new object loads in.  You should also see that evenutally, our automatic Garbage Collection process will kick in.  Memory will peak out, and then you'll see a short CPU spike as we look at all of the available objects and cull as many unused ones as possible, consumed memory will dip down significantly (as long as we can cull stuff), and then start growing again until the next time GC kicks in.  We tend to do this judiciously, as poorly-timed GC can cause games to stutter if it happens when lots of things are moving around on the display and you don't have a lot of available CPU.
    If it's our bug, it should be straightforward to fix, and I can follow up to this thread with a beta build for you guys to evaluate once we have one available.  In the meantime, it would be interesting to know if you're seeing the problem on our current Beta builds (which is where we would do the work). 
    Here's a link to the latest Beta download:
    http://labs.adobe.com/downloads/flashplayer11-5.html
    Also, the simplest example is the most actionable.  If you can find a situation where a site in a single tab reproduces the problem, that's a quick and easy thing to deal with.  If the repro case involves opening seven tabs and waiting six hours, someone needs to repeat that over and over, until they can isolate what content experiences the problem and then iterate a bunch more with a debugger attached to try and isolate the root cause.  The more complicated the content, the more difficult that is.
    Secondly, I wanted to offer some actionable suggestions that you could use now to work around this issue. 
    Try Firefox or Chrome.  Both of these browsers run Flash Player as a separate process.
    For those of you using Performance Monitor and other tools to measure, you can directly observe the resources used by Flash Player
    For the folks concerned about Bookmarks synchronization, both Firefox and Chrome provide native bookmark syncing and import from IE mechanisms. 
    Xmarks is a really nice, free utility that provides cross-browser, cross-platform bookmark synchronization.
    Thanks,
    Jeromie Clark

  • Memory leak in external interface SetReturnValue?

    I'm having trouble with a memory leak in my application. I'm
    hoping someone out there can help me find a fix or workaround, or
    tell me what I'm doing wrong.
    The leak seems to be coming from the flash external
    interface; specifically, IShockwaveFlash.SetReturnValue(String). My
    application is written in Visual Basic 2008, connecting to Flash
    9.0.124.0 (activex version).
    I've written a fairly simple flash/VB program pair to
    illustrate the problem.
    The SWF contains a button, 2 dynamic text fields, and the
    ActionScript 2 code below.
    The VB project contains a Form with a AxShockwaveFlash object
    and the VB code below.
    When this program is run, and the button is clicked a lot
    (10's of thousands of times), the application's memory creeps up
    and never seems to fall back down. If the string passed to
    SetReturnValue is longer, memory is consumed faster. But if the
    call to SetReturnValue is commented-out, the application's memory
    usage remains stable.
    If anyone has any suggestions on how to proceed, I'd be
    grateful.
    (By the way: I'm using a freeware program called DoItAgain to
    automate the button pressing.)

    I have developed two simple Java and corresponding
    C++ classes. Use code tags when you post your code.
    You are missing a lot of error checking. JNI calls, every single one, will usually be followed by some sort of error checking. Any that access classes, methods, fields or allocate object must be followed by checks for java exceptions.
    You will need to reduce your code to a smaller sample. Otherwise it is unlikely anyone will look at it.
    You also need to specify how you know that a memory leak is occurring.

  • Memory-Leak in communication of Acrobat-Flash and JS

    Hi
    The situation is as follows:
    I have a Flash-SWF (in which I have programmed a GUI)
    I have a 3D-Annotation containing an annotation-script with some functions that can be called from the GUI.
    So far so good.
    The SWF is added as overlay to a 3D-Annotation. The SWF contains some AS3-Functions, among them an enterframe-event, that keeps repeating an external-interface call to a function in the 3D Annotation-script. It works so far.
    When I tested for performance however I noticed that there is a memory-leak under these conditions. I tested my setup, and noticed the memory-useage increase by about 1 MB every 3 seconds. To further test this I stripped about everything from both the swfs Actionscript  and the annotation-JavaScript. Still the memory-useage of process "acrobat.exe*32" gradually climbs by 7-10 MB per minute. The memory-useage of "A3DUtility.exe" remains constant. Deactivating the annotation will decrease the memory-useage by a certain amount (though not to the initial value upon opening the file and starting the annotation) , but upon re-activating it immediately jumps back to the value assumed last before deactivating it. From that last value the increase starts again as well. I could observe this behaviour both in Acrobat 9 Pro Extended, Acrobat X and ReaderX.
    It seems something is wrong with the ExternalInterface-Object.

    OK, I'll do that.
    By the way, imho it's not that minor. ~1mb in two seconds sums up to ~30mb/minute, i.e. 2gb/hour. So if you leave your PDF open for some 15 minutes that's 500mb ram down the drain. Considering the file started at merely 30mb that's quite massive.

  • Memory Leak with GotoAndStop()

    I am trying to track down a solution to a memory leak within an embedded video.  If I embed a video on the timeline and then run gotoAndStop or gotoAndPlay to a specific frame every time the frame changes it takes in more memory until it crashes at about 1.7GB however if I run a straight play() on the same clip the memory usage remains constant.  I have also tried System.gc() as it is an AIR App and have tried unloadAndStop() with the embeded video being loaded into a Loader and neither can reclaim any memory.
    I am looking for a a way to resolve the memory leak or another way to be able to rapidly jump to specific frames of video as far as I know this is not possible with external flvs.
    Thanks
    Dave

    video is much like a .gif file.  if you start at frame 0 and jump to frame 30 it needs to redraw what it does nt have in frame 30  which means tellign it to start at frame 30 is the same as telling it to get all information from when it last changed which might be frame 27 to complete the frame of what should display on frame 30.
    this is why its slow to play backwards.  and best to play an flv forward.
    what i would suggest if you do not need video persay, would be to use png sequences.  but if your videos are long then i suppose it would be a greater advantage to keep it compressed.
    what is the quality as well of the video and its size and your frame rate?
    You mention that you are creating a 3d view, how is that?  do you use more than 1 swf ?
    I still think this does not sound like a play head issue, since the video is already compiled.

  • Problem Report: Severe memory leak in Flash Player 9.0

    Summary
    Flash player 9.0 is prone to a severe memory leak when
    playing SWF files produced by Captivate 1 containing full-motion
    recordings.
    Versions affected
    The problem reproduces with Flash player 9.0 (Flash9.ocx,
    Version 9.0.16.0) hosted in either Internet Explorer 6.0 or Mozilla
    Firefox 1.5 on a Windows XP SP2 system.
    The problem does not reproduce with Flash player 8.0
    (Flash8.ocx, Version 8.0.22.0) in the same environment.
    Description
    After a few minutes playing a SWF file produced by Captivate
    1 containing a full-motion recording recorded with Captivate 1, the
    host browser ends up using more than a gigabyte of memory, and the
    playback of the movie slows down to a halt, together with
    responsiveness of the whole system.
    Impact
    Our organization develops E-learning content with Captivate 1
    for various customers, mostly Fortune 100 companies.
    This bug severely limits our ability to deliver content to
    our customers.
    Steps to reproduce
    1. Using Captivate 1.01.1418, create a “blank
    movie” with default settings.
    2. Use the “Record” button and begin recording a
    full-motion movie for about 2-4 minutes. For the purposes of this
    bug, it is enough to record a user typing random text in a Notepad
    window resized to fit in the default 800x600 window.
    3. After recording the full-motion movie, publish the
    Captivate movie as a “Flash (SWF)” movie, using default
    settings (making sure that the “export HTML” checkbox
    is selected).
    4. Open the published movie’s HTML file with a host
    browser, making sure that the browser is using the Flash 9.0
    player.
    5. While the movie is playing, watch the memory usage of the
    browser process using Windows Task Manager, and you will see that
    the values of the “Mem Usage” and “VM Size”
    counters keep increasing until the system becomes unusable.

    Also see:
    http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?forumid=44&catid=184&threadid =1249396&enterthread=y
    Flash is generating around 300 page faults per second per
    flash animation
    Performance
    issues: page faulting
    Flash is also generating around 300 page faults per second.
    This can be observed by following the instructions in the link
    above for displaying page faults in the system task manager.

  • There seems to be serious flash memory leak in ie7

    Hi.. I have run into a serious memory leak issue with flash on
    internet explorer 7.0.5730.13 (everything works with firefox). It can be
    seen clearly browsing open flash charts site. Here are steps to
    reproduce:
    1) go to
    http://www.websector.de/blog/2007/10/01 ... wsmonitor/
    2) click start on WSMonitor
    3) File->New Window paste following address in address bar and click
    enter: http://teethgrinder.co.uk/open-flash-ch ... hollow.php
    4) click from chart to chart and see each time how memory increases...
    This does not happen with firefox.
    Independently to trouble shoot it wasn't any code I confirmed by making an swf file with actionscript with simply following:
    package  {
    import flash.display.Sprite;
         public class main extends Sprite {
              public function main() {
                   trace("starting3");

    hello, can you try to replicate this behaviour when you launch firefox in safe mode once? if not, maybe an addon is interfering here...
    [[Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems]]

  • Memory leak problem

    Dears,
    I have an application which have pages, each page has its content from text, images and external swfs.
    I load page only if user navigate to it, by the time, more navigation by user occures and more pages loaded.
    I don't kill ( also I couldn't kill, no destroy in as3 ) pages, becuse i need them when user go back again to it, specially that pages have interactive content which user can deal with it, like questions, so I need prevoius pages which user enterd, its content and user's data.
    The big problem is the Memory leak, the application becomes heavy , what can i do ?
    Also, if I should kill pages with its content and use GC, How can i do that ? - there is a long life and events of objects in my application.
    thank you in advance,
    heba

    I use Flash Builder , flex sdk 4.5, flash player 11.4, and windows 7 64bit
    thank you,

  • Memory leak problems with loading videos over and over.

    I'm having memory leak problems with loading videos into a VideoPlayer aswell as FLVPlayback.
    What the flash should do:
    - Should be running for 7 days without having to restart the projector.
    - Interface that shows people around a 360 3D model with 5 different parts and at the stops it makes during the rotation you can click to zoom in on a location which plays a movie for that aswell.
    - Shows a video out of 5 parts for a 360 rotation in 3D in mp4 video (added each time and cleaned up, see code below).
    - Still images are used when the video clips are done playing (MovieClip in stage).
    - Should run automatically when there is no user interaction for X minutes.
    What the problem is:
    - The flash (as a exe and swf i guess) starts to consume memory over time (say 10 hours) until the projector crashes. This usually at around 1.75 GB of memory.
    I cannot see why the Flash cannot garbage collect this and free up the memory. Mabye there is something I don't understand about the garbage collection in flash?
    Here is some code from the video loading and playing:
    var fVideo:VideoPlayer;
    VideoCreate();
    function VideoReady(pEvent:VideoEvent):void
    trace("VideoReady()");
         // start playing video
    fVideo.play();
    function VideoLoad(pUrl:String):void
         trace("VideoLoad(" + pUrl +
         VideoCreate();
         if (pUrl != "")
              if (fVideoFolder + pUrl == fVideo.source)
                   fVideo.seek(0);
    VideoReady(null);
              } else {
    trace(fVideo.state);
                   if (fVideo.state !=
    VideoState.DISCONNECTED) fVideo.stop();
    fVideo.close();                                
    fVideo.load(fVideoFolder + pUrl);
         } else {
    // error no url
    function VideoCreate():void
         trace("VideoCreate()");
         // remove old one
         if (getChildAt(0) == fVideo)
              removeChildAt(0);
         fVideo = new
    VideoPlayer(1024, 768);
         addChildAt(fVideo, 0);
         fVideo.autoRewind = false;
    fVideo.addEventListener(VideoEvent.COMPLETE, VideoDonePlaying);
    fVideo.addEventListener(VideoEvent.READY, VideoReady);

    Hmm. It's in connection with Dropbox. Så apparantly you can only use one of the two at the same time if you want the programs integrated in Finder.

  • Memory leak while debugging but not in release version

    I have an Adobe AIR application that must load and unload multiple external swfs, and it must run for hours.
    I had an issue where there was a memory leak. I tried all kinds of fixes, including rolling back SDKs and Adobe Runtime,
    but every time I tested in Flashbuilder, the memory would climb, and with each unload a FlexLoader would stay in memory.
    Finally I tried creating a release build, and low and behold the memory did not climb. It stayed the same even under stress testing.
    So evidently, the memory leak had to do with debug version, and once it was a release version, the leak disappeared.

    UPDATE: The problem was with the external swfs being loaded into the main application.
    If I compiled them in debug, they leaked. In release version they did not.

  • External interface memory leak?

    Hello,
    I am embedding the flash player inside a Visual C++
    application. My program uses the external interface extensively.
    The external interface is called several times a second ( ~20 fps )
    each time a ~1k XML string is passed to the flash player.
    During execution the program increases its memory by ~10 Mega
    each hour. I have used the Umdh tool to try to locate the problem.
    It points to the line where the container program uses the external
    interface to call a function inside the swf movie.
    Below is a typical output of the Umdh tool:
    + 3396588 ( 3405883 - 9295) 261991 allocs BackTrace12EF
    + 261276 ( 261991 - 715) BackTrace12EF allocations
    ntdll!RtlpNtMakeTemporaryKey+000074D0
    ntdll!RtlInitializeSListHead+00010D08
    ntdll!wcsncat+00000224
    FlDbg9c!DllUnregisterServer+0010261A
    FlDbg9c!DllUnregisterServer+0010263C
    FlDbg9c!DllUnregisterServer+0000F1B7
    myProgram!CZFlash::CallFunction+0000004D (c:\documents and
    settings\amit\my documents\visual studio projects\ myProgram
    \zflash\zflash.cpp, 255)
    myProgram!MainDialogProc+000012A2 (c:\documents and
    settings\amit\my documents\visual studio projects\ myProgram
    \w32\maindlg.cpp, 2324)
    USER32!GetDC+0000006D
    USER32!PrivateExtractIconExW+000002B2
    USER32!PrivateExtractIconExW+000000FE
    USER32!DefDlgProcW+00000022
    USER32!GetDC+0000006D
    USER32!GetDC+0000014F
    USER32!IsWindowUnicode+000000A1
    USER32!CallWindowProcW+0000001B
    COMCTL32!Ordinal11+00000328
    COMCTL32!RemoveWindowSubclass+0000017E
    COMCTL32!DefSubclassProc+00000046
    COMCTL32!Ordinal389+000028DF
    COMCTL32!RemoveWindowSubclass+0000017E
    COMCTL32!DefSubclassProc+00000046
    COMCTL32!Ordinal389+000028DF
    COMCTL32!RemoveWindowSubclass+0000017E
    COMCTL32!DefSubclassProc+00000046
    COMCTL32!Ordinal389+000028DF
    COMCTL32!RemoveWindowSubclass+0000017E
    COMCTL32!DefSubclassProc+00000046
    COMCTL32!Ordinal389+000028DF
    COMCTL32!RemoveWindowSubclass+0000017E
    COMCTL32!DefSubclassProc+00000046
    COMCTL32!Ordinal389+000028DF
    The System.totalMemory value of the flash player ranges from
    2.2 Mbyte to 3.2. I tried using memory leak detection software like
    IBM's Purify but couldn't find the problem.
    I also tried to disable the BSTR caching by setting the
    environment variable OANOCACHE, but the memory of my program
    continues to increase.
    Below is my C++ code. The m_iflash object is a pointer to the
    ActiveX of the flash player.
    wstring CZFlash::CallFunction(wstring call_string)
    BSTR pcall_string = SysAllocString(call_string.c_str());
    BSTR presponse = NULL;
    HRESULT status = m_iflash->CallFunction(pcall_string,
    &presponse);
    SysFreeString(pcall_string);
    if (status != S_OK)
    if (presponse != NULL)
    SysFreeString(presponse);
    return L"";
    wstring sresponse(presponse);
    SysFreeString(presponse);
    return sresponse;
    Currently the swf movie contains only action script that
    displays the System.totalMemory value and an empty function that
    the external interface calls.
    Any help will be appreciated.
    Thanks in advance,
    Amit

    Hello,
    Thanks for coming to National Instruments Discussion Forum.
    Can you give us more details about your application? Basically, I can’t find your main VI for your User Interface. Can you also give us the different steps to do to run your application and reproduce your problem?
    Generally speaking, your code on your block diagram have to be displayable in one screen.
    Benjamin R.
    R&D Software Development Manager
    http://www.fluigent.com/

  • Large Memory Leak?

    I've got a container mc that I'm duplicating and
    loading videos into. I have 15 swf videos I'm loading
    into each mc. Each swf loaded is about 2mb in size
    which equates to 30mb of total loaded swfs.
    Each swf contains about 90 keyframes, each with
    one image in a sequence that plays an animation.
    After all the videos are loaded there are no other
    movieclips created or duplicated.
    I have arrow controls that allow me to rewind these
    videos and fast forward them.
    Everything works fine. But I'm noticing now that
    as I rewind / fastworward these swfs my memory
    is being gobbled up. It seems that my memory
    goes up almost per frame that I rewind / fastworward,
    and once the whole animation has played the memory
    plateus, until I start to play one of the other unplayed
    animations.
    The only thing I'm doing with the rewind and fastforward
    buttons is just a gotoAndPlay(prev / next frame).
    I don't understand why my memory is being eaten up,
    Seems like if the files loaded are only 30mb then the
    memory shouldn't be terribly more than that.
    Any ideas or help in finding what would be causing the
    memory leak?
    Thanks.

    To rewind / fastforward the clips I am just calling
    gotoAndPlay(back / forward 1 frame).
    Thats all I call. It seems like the jpgs that are on each
    keyframe are compressed
    inside the SWF but then when they are shown on the screen
    they are loaded into
    memory. As I go through each new frame I can see my memory
    going up...once I
    play through the entire movie my memory plateaus...then the
    process repeats once
    I start to play the next movie...it just goes up and up.
    Any way to clear memory or something like that without
    unloading the movies?
    Thanks.

  • IE Memory Leak for addCallback

    Everytime I register:
               ExternalInterface.addCallback("reload",reload);
    or any other ExternalInterface.addCallback
    I see memory leaks.  Even if its not called.  Does anyone know how to mitigate this?
    Also, I can't seem to get flash to release it's memory unless I close IE.  Is there another way?  I've already tried removeAll in extJS but it doesn't seem to work.  The element is removed but the memory is still being used. 
    thanks
    Pascal

    I believe that bug has not been fixed yet.  I don't know of any workarounds
    for the main app.  For child SWFs, proxy all calls through the main app.
    It also looks like you're trying to reload, but you might be better off
    resetting the app.

Maybe you are looking for

  • Expanding Raid 5 array (with windows 2003)

    I recently put 2 more 500GB drives into my existing 4 drive Raid 5 setup. I went through the expansion through RAID ADMIN 1.5. It synced the array which took about a day and inside the RAID ADMIN 1.5 tool it says the array is now 2.27 TB. Inside wind

  • File Hyperlinks - How to hide the extension?

    Hi, I'm trying to link to a file but I'm finding that the format of the hyperlink is not very customisable. For example, I want to link to a file called eulogy.doc but just have the link read Eulogy. I have tried hiding the extension on the file, but

  • ITunes 10.5 sync doesn't finish iPhone 4S 5.0.1

    When syncing my iPhone 4S 16GB 5.0.1 with itunes 10.5 using a Macbook Pro 10.7.2 it freezes at the last step 7 of 7. I had the same problem with iOs 5.0 and the update didn't change a thing. iTunes is still accesible, but it doesn't finish the sync.

  • Hyperlinks do not function properly in Internet Explorer

    I'm having a problem exporting HTML from Muse to a SharePoint folder. I export the Muse files successfully to a SharePoint folder and then can view the Index file or any of hte created HTML pages. My problem is when using Internet Explorer (IE8) spec

  • Sending attachments in Mail is Very, Very Difficult

    I have sent numerous notes on this before, but it is INCREDIBLY annoying when family, friends, business associates and more continue to ask me to RE_SEND attachments because they cannot see, view, download my attachments. This was NEVER-EVER an issue