From: Michael E. <Mic...@il...> - 2001-02-12 20:48:20
|
I can confirm this behavior on IE 4.x and NN 4.x. We also noted where the IE leak was about 1 - 2Meg, the NN leak was only 20 - 40K. Our application has 2 nested layers containing a scrollpane, containing tables. We tried deleting, removing, and setting various objects/elements = null but nothing would get the memory to budge. When we dropped the number of layers down to even one, the same behavior occured. This leak is a major problem for us at this time, any help would be greatly appreciated. Mike Ellis -----Original Message----- From: Eytan Heidingsfeld [mailto:ey...@tr...] Sent: Monday, February 12, 2001 09:44 To: Dynapi-Dev Subject: [Dynapi-Dev] Freeing Memory in IE I have recently found very interesting behavior in IE 5. I used proprietary code so I don't know about IE4 and NN4 but I will check soon. I used code to create many DynLayers (520) inside another dynlayer(myLayer). Then I called document.body.removeChild(myLayer) the memory didn't budge. Then I minimized and maximized the browser. Walla! from 13MB to 1MB. (This with the Loop to nullify the DynLayers for they are still there taking up memory). Here is the code to test: ==================================== <html> <head> <title>DynAPI Distribution: Destroy</title> <script language="Javascript" src="../src/dynapi.js"></script> <script language="Javascript"> DynAPI.setLibraryPath('../src/lib/'); DynAPI.include('dynapi.api.*'); </script> <script language="Javascript"> var mLayer; var a = []; function dowork(){ for(var i=0;i<101;i++){ a[i] = null; } document.body.removeChild(mLayer.elm); } DynAPI.onLoad = function() { mLayer = new DynLayer(); mLayer.setHTML("testing memory free in IE"); DynAPI.document.addChild(mLayer); window.status = "ready for action"; for(var i=0;i<521;i++){ a[i] = new DynLayer(); mLayer.addChild(a[i]); } } </script> </head> <body bgcolor="#ffffff"> <a href=javascript:dowork()>Start The Test</a> </body> </html> ====================================== |