NIB Resource Memory Leak

I have a question: I have an application that uses lots of views and I tend to load them with NIBs:
MemoryManagementTestViewController *
newViewController = [[MemoryManagementTestViewController alloc] initWithNibName:@"MemoryManagementTestView" bundle:nil];
[self.navController pushViewController:newViewController animated:YES];
[newViewController release];
After I pop the above view controller off the navigation stack, its viewDidUnload() and dealloc() methods are called (below for a test view controller I created to try to isolate the cause of the problem).
The Object Allocation instrument tool shows that a number of control initWithCoder methods (such as UITextField initWithCoder) are consuming memory.
I realize that I am not using the recommended coding style for outlets (my 10 test labels and 10 test text fields), but I have tried to the recommended property style as well.
I cannot think of anything that I am not freeing, but the combination of the code above and below results in a persistent leak, at least according to the object allocator instrument application (though not with the memory leaks tool). Eventually the application runs out of memory as didReceiveMemoryWarning() is called.
I looked at your sample source code, and it appears that most of your sample applications load their views at startup instead of creating and freeing them as I am attempting to do. Is that necessary? If not, is there some trick to free NIB resources?
- (void)viewDidUnload
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
[label1 release];
[label2 release];
// ... labels 3-10 released too.
label1 = nil;
label2 = nil;
// ... labels 3-10 set to nil.
[text1 release];
[text2 release];
// text fields 3-10 released too.
text1 = nil;
text2 = nil;
// text fields 3-10 set to nil.
return;
- (void)dealloc
self.navigationItem.leftBarButtonItem = nil;
[self setView:nil];
[super dealloc];
return;
}

secretagentstuart wrote:
looked at your sample source code, and it appears that most of your sample applications load their views at startup instead of creating and freeing them as I am attempting to do.
Would those be 'Beginning iPhone Development' samples, by any chance?

Similar Messages

  • T61 with memory leak on XP for driver battc.sys

    Hi
    I have an issue with XP where the battc.sys module that is part of Windows XP and responsible for the kernel side of monitoring the battery status. This module continually leaks memory until I have no more kernel paged resources left and programs start to fail on my laptop.
    I raised a support case for this with Microsoft and after some investigation and upgrading to the latest T61 power drivers that were released a few days ago on the Lenovo site, MS support told me it is a fault of the T61 and that I would need to disable Microsoft APCI support to stop this memory leak from occuring and to take the issue up with Lenovo.
    I have used the verifier tool to confirm that it is the Windows XP SP3 battc.sys memory module leaking.
    I am running the latest T61 drivers and fully patch with MS drivers on SP3.
    As MS have told me it is the fault of the T61 I am posting this issue here.
    Thanks
    Stephen

    It is memory available to the kernelwhich itself does not show under a process in task manager as far as I am aware (unles it is taken account as part of the system process).
    The best way to measure the available kernel memory space available is by using sysinternals procexp.
    You need to download procexp and also install the windows debugging tools from Microsoft. Then in procexp set the "Options > Configure Symbols : Debughlp.dll path" to the new debughlp.dll installed with your debu tools and set the symbols path to srv*c:\Symbols*http://msdl.microsoft.com/download/symbols
    Then you can choose in procexp "View > System Information" and see the used and total paged and non-paged kernel memory space.
    poolmon helps monitor all the symbols that are taking up this memory and verifier lets you drill down to the exact module and the changes in memory for a module that is occuring.
    Here are two really good links on it
    http://blogs.msdn.com/ntdebugging/archive/2006/12/18/Understanding-Pool-Consumption-and-Event-ID_3A0...
    http://blogs.msdn.com/ntdebugging/archive/2008/05/08/tracking-down-mmst-paged-pool-usage.aspx
    In my poolmon i notice that Mmst and battc are taking alot of memory after my computer has been running for some time. Mmst being high is normal but battc should not continually be growing as it is which is why I raised the case to MS but they want verification it is not a Lenovo issue.

  • Address Book Sync Memory Leak

    Address Book Sync Memory Leak , Using 5.6GB of Real Memory
    Has anyone had issues with this? I have to force quit the process from Activity Monitor every 30 minutes.
    Sampling process 3337 for 3 seconds with 1 millisecond of run time between samples
    Sampling completed, processing symbols...
    Analysis of sampling AddressBookSync (pid 3337) every 1 millisecond
    Process:         AddressBookSync [3337]
    Path:            /System/Library/Frameworks/AddressBook.framework/Versions/A/Resources/AddressBo okSync.app/Contents/MacOS/AddressBookSync
    Load Address:    0x100000000
    Identifier:      AddressBookSync
    Version:         ??? (???)
    Code Type:       X86-64 (Native)
    Parent Process:  SyncServer [3314]
    Date/Time:       2011-05-30 10:09:28.670 -0400
    OS Version:      Mac OS X 10.6.7 (10J869)
    Report Version:  7

    Unfortunately not. No groups and any Mobile Me account here not even many contacts (436) and any duplicates except in Ical after having restored my iphone 4 times. Something strange too, 2 weeks ago, Isync was running while I'm not registered on MM nor Icloud (turned off on my iphone) . Maybe a conflict between Outlook, Addressbook, Itunes and Isync on SL....I'm going crasy with this issue It reminds me of Windows ! Thx anyway, I'm gooing to contact apple in the following days.

  • Memory leak in Tomcat 5.5

    Hi all, i am experiencing memory leaks while using tomcat 5.5 and mysql connector 3.1.7.. While running the attached code tomcat swallows up to 20 mb and doesnt return it. I close down everything but the app still leaks mem. For now it's not an issue (Tomcat stays below 60mb mem of 1gb), however running this app on serveral clients will dramatically increase the memory allocation.
    import java.sql.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.awt.Image;
    import java.awt.Graphics2D;
    import java.awt.geom.AffineTransform;
    import java.awt.image.BufferedImage;
    import javax.swing.ImageIcon;
    import com.sun.image.codec.jpeg.JPEGCodec;
    import com.sun.image.codec.jpeg.JPEGImageEncoder;
    public class Thumbs extends HttpServlet {
      private String dbDriver = "com.mysql.jdbc.Driver";
      private String dbURL = "jdbc:mysql://localhost/webapp?";
      private String userID = "javauser";
      private String passwd = "javadude";
      private Connection dbConnection;
      //Initialize global variables
      public void init() throws ServletException {
      //Process the HTTP Get request
      public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        try{
           String maxDim = "";
           String siteString = request.getParameterValues("s")[0];
           if (request.getParameterValues("d") != null){
               maxDim = request.getParameterValues("d")[0];
           if (maxDim == ""){
               response.setContentType("image/jpeg");
               OutputStream out = response.getOutputStream();
               writePicture(out,siteString);
           else{
               if (siteString != null) {
                   int maxDimension = Integer.parseInt(maxDim);
                   response.setContentType("image/jpeg");
                   OutputStream out = response.getOutputStream();
                   writeThumbnailPicture(out, siteString, maxDimension);
        } catch (Exception ex){
            ex.printStackTrace();
            log(ex.getMessage());
      public void writePicture(OutputStream out, String siteID){
          try{
              Class.forName(dbDriver);
              dbConnection = DriverManager.getConnection(dbURL, userID, passwd);
              PreparedStatement stmt = dbConnection.prepareStatement("select * from webcatalog where ID = ?");
              stmt.setString(1,siteID);
              stmt.executeQuery();
              ResultSet rs = stmt.getResultSet();
              if (rs.next()) {
                  byte[] data = rs.getBytes("Picture");
                  if (data != null) {
                      Image inImage = new ImageIcon(data).getImage();
                      BufferedImage outImage = new BufferedImage(inImage.getWidth(null),
                                                                 inImage.getHeight(null),
                                                                 BufferedImage.TYPE_INT_RGB);
                      // Paint image.
                      Graphics2D g2d = outImage.createGraphics();
                      g2d.drawImage(inImage,null,null);
                      // JPEG-encode the image
                      JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(out);
                      encoder.encode(outImage);
                      out.close();
              rs.close();
              stmt.close();
              dbConnection.close();
          }catch(Exception ex){
              ex.printStackTrace();
      public void writeThumbnailPicture(OutputStream out,String siteID,int maxDimension){
        try{
          Class.forName(dbDriver);
          dbConnection = DriverManager.getConnection(dbURL, userID, passwd);
          PreparedStatement stmt = dbConnection.prepareStatement("select * from webcatalog where ID = ?");
          stmt.setString(1,siteID);
          stmt.executeQuery();
          ResultSet rs = stmt.getResultSet();
          if (rs.next()) {
            byte[] data = rs.getBytes("Picture");
            if (data != null) {
              Image inImage = new ImageIcon(data).getImage();
              // Determine the scale.
               double scale = (double)maxDimension / (double)inImage.getHeight(null);
               if (inImage.getWidth(null) > inImage.getHeight(null)) {
                   scale = (double)maxDimension /(double)inImage.getWidth(null);
               // Determine size of new image.
               // One of them should equal maxDim.
               int scaledW = (int)(scale*inImage.getWidth(null));
               int scaledH = (int)(scale*inImage.getHeight(null));
               // Create an image buffer in
               //which to paint on.
               BufferedImage outImage = new BufferedImage(scaledW, scaledH,
                   BufferedImage.TYPE_INT_RGB);
               // Set the scale.
               AffineTransform tx = new AffineTransform();
               // If the image is smaller than
               // the desired image size,
               // don't bother scaling.
               if (scale < 1.0d) {
                   tx.scale(scale, scale);
               // Paint image.
               Graphics2D g2d = outImage.createGraphics();
               g2d.drawImage(inImage, tx, null);
               g2d.dispose();
               // JPEG-encode the image
               JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(out);
               encoder.encode(outImage);
               out.close();
          rs.close();
          stmt.close();
          dbConnection.close();
        catch(Exception ex){
          ex.printStackTrace();
      //Clean up resources
      public void destroy() {
      private void jbInit() throws Exception {
    }

    you can try this:
    open your connection outside the function, and then pass it like as a parameter...
    writePicture(OutputStream out, String siteID, Connection conn)
    this can solve the problem because opening the connection inside the function spends a lot of memory...
    Hope this can help you
    Regards
    Fernando

  • 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 DataService

    Hi All,
          I had posted this query to couple of other groups ..I am still struglling with this issue..Hope someone  will  help me out here
          I have  very basic application which uses  DataSerives over RTMP channel  to populate dataGrid , I have not used any  user defined component.
    This application has got LOAD data and Remove data  Button just to simulate the actual application
    What happens , when I click on LOAD data , It  loads the data from server(JBOSS) then I Remove all the data and force the GC to run
    If I continuously keep loading and removing the  data ,  memory goes up every time and after some times It reaches to threshold and  finally crashes the Browser.
    In actual application as soon as user logs in a dedicated DS destination is created..
        private function createDestination(destName:String):void{
                 var remoteService:RemoteObject = new RemoteObject("DestinationManager");
                 remoteService.addEventListener(ResultEvent.RESULT, resultHandler,false,0,true);
                 var operation:AbstractOperation = remoteService.getOperation("createDestination");
                 operation.send(destName);
                 var cs:ChannelSet = new ChannelSet();
                 var rtmpChannel:RTMPChannel = ServerConfig.getChannel("my-rtmp") as  RTMPChannel;
                 cs.addChannel(rtmpChannel);
                 tradeService = new DataService() ;
                 tradeService.destination=destName;
                 tradeService.channelSet = cs;  
    Now when user hits on Load data button to load the trade data ...
       public function loadData():void
             var remoteService:RemoteObject  = new RemoteObject("filterRemoteVO");
             var operation:AbstractOperation = remoteService.getOperation("loadData");
             tradeService.fill(tradeCollection);
             operation.send(rowData.text ,GUIID);
             tradeList.dataProvider = tradeCollection;
    Remove Data  hit I clean all the resource and released collection :-
          public  function  removeAll():void{
             if(tradeList.dataProvider){
                  tradeCollection.source = new Array();
                  tradeList.dataProvider.source = new Array();
                  tradeList.dataProvider = null;
                tradeService.release();
               tradeService.releaseCollection(tradeCollection);
              tradeService.channelSet.disconnectAll();
              tradeService.disconnect();
               tradeService.logout();
               System.gc();
    Except these 3 function I don't have any code which could cause memory leak.
    I m using
    LCDS 2.5
    Flex 3.0
    JBoss4.2
    Please see the mxml file below   , If  possible please have a look at it , I might  not be using dataSerice API correctly.
    I have been trying to solve this leak for last two week , I really need help from you guys.
    My client has already evaluating other contemporary technology because of this memory issue.
    I have also created scalled down war file which can be deployed on any  java application server.
    Any help will greatly be appreciated
    Regards,
    Dam
    ######################## MXML##########################
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"
          creationComplete="init();" height="100%" width="100%"
         >
         <mx:Script >
         <![CDATA[
             import mx.containers.GridRow;
               import mx.utils.Base64Decoder;
             import mx.utils.StringUtil;
                import mx.events.CollectionEvent;
             import mx.formatters.Formatter;
             import mx.events.ResizeEvent;
             import mx.controls.DataGrid;
             import mx.effects.Fade;
             import mx.events.DataGridEvent;
             import mx.utils.ObjectUtil;
             import mx.events.ScrollEvent;
           import mx.formatters.DateFormatter;
           import mx.events.ListEvent;
           import mx.data.mxml.DataService;
           import mx.messaging.config.ServerConfig;
           import mx.messaging.channels.RTMPChannel;
           import mx.messaging.ChannelSet;
           import mx.rpc.AbstractOperation;
           import mx.rpc.remoting.RemoteObject;
           import mx.collections.ArrayCollection;
           import mx.controls.Alert;
           import mx.rpc.events.ResultEvent;
           import mx.messaging.messages.*;
           import mx.messaging.events.*;
           import mx.controls.Alert;
            private var GUIID:String;
            private var lastRollOverIndex:Number;
            public var tradeService:DataService=null;
            public var tradeCollection:ArrayCollection = new ArrayCollection();
           public var flag:Boolean = false;
            private function init():void {
               var guiId:String ="TEST";
                createDestination(GUIID);
            public function getData():void{
                 // memory.text =""+ ((System.totalMemory / 1024)/1024);
            public function releaseDataServices():void {
               //  tradeService.fill(null);
                    tradeService.release();
                   // tradeService.releaseCollection(tradeCollection);
                   tradeService.channelSet.disconnectAll();
                    tradeService.disconnect();
                    tradeService.logout();
                    //tradeService.dataStore = null;
                    /*Function for creating destination*/
              private function createDestination(destName:String):void{
                 var remoteService:RemoteObject = new RemoteObject("DestinationManager");
                 remoteService.addEventListener(ResultEvent.RESULT, resultHandler,false,0,true);
                 var operation:AbstractOperation = remoteService.getOperation("createDestination");
                 operation.send(destName);
                 var cs:ChannelSet = new ChannelSet();
                 var rtmpChannel:RTMPChannel = ServerConfig.getChannel("my-rtmp") as RTMPChannel;
                 cs.addChannel(rtmpChannel);
                 tradeService = new DataService() ;
                 tradeService.destination=destName;
                 tradeService.channelSet = cs;  
             //This function calls dataservice fill method depending on wheather destination is created or not
            private function resultHandler(event:ResultEvent):void{
               //call data service as destination is created successfully
                var status:Boolean = event.result as Boolean
               // Alert.show("status="+status);
                if(status){
                 getData();
               else{
                   //TODO report error to MATS app  
          public  function  removeAll():void{
             if(tradeList.dataProvider){
                  tradeCollection.source = new Array();
                  tradeList.dataProvider.source = new Array();
                  tradeList.dataProvider = null;
                tradeService.release();
               // tradeService.releaseCollection(tradeCollection);
              tradeService.channelSet.disconnectAll();
              tradeService.disconnect();
               tradeService.logout();
               System.gc();
           public function loadData():void
             var remoteService:RemoteObject  = new RemoteObject("filterRemoteVO");
             var operation:AbstractOperation = remoteService.getOperation("loadData");
             tradeService.fill(tradeCollection);
             operation.send(rowData.text ,GUIID);
             tradeList.dataProvider = tradeCollection;
       ]]>
    </mx:Script>
          <mx:DataGrid   id="tradeList"
                 initialize="tradeList.dataProvider = tradeCollection" horizontalScrollPolicy="auto"
                   height="659" x="0" y="84">
                <mx:columns>
                     <mx:DataGridColumn  headerText="Security Description" dataField="securityDesc"
                      />
                     <mx:DataGridColumn  headerText="B/S" dataField="transactionType"
                     />
                     <mx:DataGridColumn  headerText="Amount" dataField="amount"
                     />
                     <mx:DataGridColumn  headerText="Price Text" dataField="priceText"
                     />
                     <mx:DataGridColumn  headerText="Counterparty" dataField="counterParty"
                     />
                     <mx:DataGridColumn  headerText="Trade Date" dataField="tradeDate"
                     />
                     <mx:DataGridColumn  headerText="Settle Date" dataField="settleDate"
                     />
                     <mx:DataGridColumn  headerText="Trade Status" dataField="tradeStatusId"
                     />
                     <mx:DataGridColumn  headerText="Trader" dataField="trader"
                     />
                     <mx:DataGridColumn  headerText="Salesperson" dataField="salesperson"
                     />
                     <mx:DataGridColumn  headerText="Ticket Number" dataField="tradeNumber"
                     />
                     <mx:DataGridColumn  headerText="Entry Date" dataField="tradeTime"
                     />
                     <mx:DataGridColumn  headerText="Cancel Date" dataField="cancelDate"
                     />
                     <mx:DataGridColumn  headerText="Cancel Time" dataField="cancelTime"
                     />
                 </mx:columns>
              </mx:DataGrid >
             <mx:Grid x="149" y="23" width="995">
                     <mx:GridRow width="100%" height="100%">
                                <mx:GridItem width="100%" height="100%">
                                     <mx:Label text="Enter No of obejcts"   width="111"/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:TextInput name="row" id="rowData"   width="97"/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:Button  label="Load Data" click='loadData()'/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:Button  label="removeAll" click='removeAll()'/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:Label text="Total Memory"/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:TextInput text="Total Memory" id="memory"   width="97"/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:Label text="Grid Row Count"/>
                             </mx:GridItem>
                             <mx:GridItem width="100%" height="100%">
                                     <mx:TextInput name="GridRowCountN" id="GridRowCount"   width="97"/>
                             </mx:GridItem>
                     </mx:GridRow>
             </mx:Grid>
    </mx:Application>

    Hi Natasha,
    Sorry for late reply.
          I tried your suggestion but It did not help to release memory. Actully,this app contains only one event handler which is for remote method call , I dont think this could cause any memory leak.
    Profiling session reveals that It is the issue of DataService class.I dont know How do I convince  Adobe to investigate this issue.
    Regards,
    Dharmendra

  • Memory leak in Waveform Graph?

    Either thier is a huge memory leak in the waveform graph or I am really doing something wrong.
    I created an example app with a waveform graph and a button the contructor looks as follows:
    Form1(void)
    InitializeComponent();
    vals = gcnew array<double>(60000) ;
    for (int i=0; i<60000; i++)
    vals[i]=Math:in(Math:: PI*2*60/6000.0*i) ;
    and the click event looks like this:
    System::Void button1_Click(System:: Object^ sender, System::EventArgs^ e)
    this->waveformGraph1->Plots->Clear() ;
    NationalInstruments::UI::WaveformPlot^ plot = gcnew NationalInstruments::UI::WaveformPlot(xAxis1, yAxis1) ;
    plot->PlotY(vals) ;
    plot->LineColor = Color::Red ;
    this->waveformGraph1->Plots->Add(plot) ;
    every time I click the button the memory used on my system goes up by about 10 MB.  I tried this also with using this->waveformGraph1->PlotY(vals) and the memory usage stays solid as a rock.
    Am I doing something wrong or what is causing the leak so I can work around it, my program plots 4 arrays of this size on one graph per test result.

    The plot uses some unmanaged resources (gdi objects and other handles), which is why it implements IDisposible. Because of the GC, resource cleanup is not deterministic, clean up occurs when the GC deems it necessary. Calling delete (which based on C++/CLI syntax) ultimately ends up calling Dispose and this forces the object to release any handles it might have immedietly. See the documentation for the .NET Dispose pattern for more information.
    If you don't call delete, what would end up happening is that eventually at some point in the application, the GC would fire and cleanup all the objects and handles and you would see a drop in the applications memory footprint, but you would need to run the application for a while before that might happen. In a long application run, things would end up stabilizing.
    Bilal Durrani
    NI

  • Memory Leak in Adobe Premiere CC on Windows

    I installed Premiere CC on Windows 7 ( Intel Core i7-3770K [email protected] GHz, 16GB RAM). Software has a serious memory leak. After less than hour working on a very simple project (no rendering, no effects) memory usage  reached 15 GB, at which point Premiere stopped responding. After closing and reopening software memory usage again started to increase. I was testing it by just scrubbing over timeline, no editing, memory usage still slowly crept-up. I called Adobe technical support, they tried to tell me, that this is normal. Right! It is normal to be forced to close and reopen application every hour? I do not think so. I have Premiere CC also installed on my MAC Book Pro, checked memory usage on much bigger project, it was steady, not creeping up, using beween 1 and 2 GB.  I checked forums for this problem, there are several posts, but have not found any response from Adobe regarding this.
    Update:
    Tonight I continued working on same small project, within 2 hours I had to shut down Premiere 3 times. I also limited in setting memory Premier can use, that did not make any difference, usage by Premiere went to maximum - total 16 GB with about 2 GB taken by system and other stuff running. I am monitoring memory usage on resource monitor. Used Physical memory went 100 %, Commit Charge about 60%. This so far happened three times  in a row.
    Adobe, can you hear me?
    Milan
    Message was edited by: milan-to
    Message was edited by: milan-to

    Adobe, can you hear me?
    Not guaranteed when posting here.  Try below instead.
    https://www.adobe.com/cfusion/mmform/index.cfm?name=wishform
    Having said that, this is not a problem I see on any of the four Windows machines I work on.  And it's not a problem commonly reported here.  So my inclination is to suggest that something may be funky with your install.

  • Memory leak using Oracle thin driver on wls6.1...

    Hi, I've been attempting to find a memory leak in an application that
    runs on WLS 6.1 SP2, on Solaris 8 and accessing an Oracle 9i db. We
    are using the Type 4 (Thin) driver and JProbe reports that hundreds of
    oracle.jdbc.* objects are left on the heap after my test case
    completes. Specifically oracle.jdbc.ttc7.TTCItem is the most common
    loiterer on the heap. I have verified that after each database access
    the resources are release correctly (i.e. ResultSet, Connection,
    PreparedStatement, etc.)
    Has anyone encountered similar problems? or does anyone know how to
    fix this?
    Thanks,
    Tim Watson

    Hi Tim!
    We have seen problem using oracle 817 client that has been resolved using
    901 client for type2(oci) driver, But i am not aware of thin driver
    problem. You should check with oracle if they have find any customer's
    with this problem.
    Thanks,
    Mitesh
    Tim Watson wrote:
    Hi, I've been attempting to find a memory leak in an application that
    runs on WLS 6.1 SP2, on Solaris 8 and accessing an Oracle 9i db. We
    are using the Type 4 (Thin) driver and JProbe reports that hundreds of
    oracle.jdbc.* objects are left on the heap after my test case
    completes. Specifically oracle.jdbc.ttc7.TTCItem is the most common
    loiterer on the heap. I have verified that after each database access
    the resources are release correctly (i.e. ResultSet, Connection,
    PreparedStatement, etc.)
    Has anyone encountered similar problems? or does anyone know how to
    fix this?
    Thanks,
    Tim Watson

  • Memory leak issues persist in Safari 6.0.5 (it's about time that Apple actually fixed this)

    Safari has been notorious for its memory leaks for years, as I'm sure many of you know. I stopped using Safari as my main browser in 2010 or so, and I instead began to use Chrome. However, I recently had to use Safari to access some webpages, and I neglected to quit out of it. A few hours later, my computer slowed to a complete crawl. I was confused, because my computer never slows down to such a crawl, so I went into Activity Monitor to find the 'Safari Web Content' process using all of my available RAM, which was nearly 6 GB. Needless to say, Safari was force quit after that. I've heard that some plugins will cause this, but Flash was my only active plugin. Flash is, indeed, a heaping pile of crap that will readily eat resources as it sees fit- but this never happens to me in Chrome, and I use Flash all of the time n Chrome. This was after it had been sitting idle for quite some time, and I imagine that it would have used more RAM if it could.

    Using 6.0.5 here without any of those issues ...
    Regardless of whether Flash is being used, from your Safari menu bar click Help > Installed Plug-ins.
    Try troubleshooting extensions and third party plug-ins.
    From your Safari menu bar click Safari > Preferences then select the Extensions tab. Turn that off if there are any installed. Quit and relaunch Safari to test. If that helped, turn extensions back on then uninstall one a time to test.
    If it's not an extensions issue, try troubleshooting third party plug-ins.
    Back to Safari > Preferences. This time select the Security tab. Deselect:  Allow all other plug-ins. Quit and relaunch Safari to test.
    If that made a difference, instructions for troubleshooting plugins here.
    my computer slowed to a complete crawl.
    Checked to see exactly how much space is available ??
    Click your Apple menu icon top left in your screen. From the drop down menu click About This Mac > More Info > Storage
    Make sure there's at least 15% free disk space.
    Checked the startup disk lately?
    Launch Disk Utility located in HD > Applications > Utilities
    Select the startup disk on the left then select the First Aid tab.
    Click:  Verify Disk  (not Verify Disk Permissions)
    If the disk needs repairing, restart your Mac while holding down the Command + R keys. From there you can access the built in utilities in OS X Recovery to repair the startup disk.
    message edited by:  cs

  • Maximize server uptime - memory leak?

    Since we stabilized the newly introduced WLI 8.1 application we are now fine tuning the JVM. We are facing some kind of memory leak which forces us to reboot the WLS instances daily.
    I'm now asked to identify some strategies how we could let the WLI instances run for longer than 1 day. My goal is 7 days, so that the machines must only be touched once a week. The relevant JVM settings are like this:
    -Xms2048m -Xmx2048m -Xmanagement -Djrockit.managementserver.port=30011 -XgcPrio:throughput
    I've choosen the "throughput" strategy as we have here a systems which acts asynchronously most of the time (WLI). I have attached two JRA records. The first ("1day") shows a system which has an uptime of now 16 hours. The heap utilization is almost all the time between 90%-100%. Things get worse after a while. In the consequence we are rebooting the server when we see more and more timeout-exceptions in our WLI layer and heavy GC activity ("average time spent in GC")
    The other record ("leakdetector") shows a system which is now running for almost 3 hours. Here I connected the memory leak detector. The graph looks a bit better / more balanced. Means, that after 3 hours the avg heap util remains between the margins of 40-50 %. The trend of the bottom margin however clearly indicates an increasing memory footprint.
    To understand this in more detail I started using the memory leak analyzer. So far I got no benefit from using the tool, though it looks very impressive. However, when I connect the memory leak analyzer I can observe some strange heap graph changes. I suppose the memory leak detector has some impact onto the GC strategies, doesn't it? My heap graph looks totally different with no leak detector attached. What can be the reason on this?
    Also I'm quite a bit confused why the "Growth" indicator always stays at 0 bytes/sec, even when I can see that objects are getting bigger and bigger. What is the secret here?
    i appreciate every comment you have on my case,
    thanks a lot

    You might also look at approaching the problem for a different perspective. Which transactions, requests, components are creating the most amount of memory? What concurrent requests where active when the memory jumped or an OOME was thrown. I have found this approach effective in getting a good idea on where to focus memory diagnostics after ruling of course a resource capacity issue.
    The following article discusses the difference between a leak and a capacity problem.
    http://www.jinspired.com/products/jxinsight/outofmemoryexceptions.html
    Also you should try high level monitoring to see whether there are global patterns in metric data that provides clues. This blog entry shows what is possible with professional performance management tools with visualizations going beyond pie charts and table views.
    Beautiful Evidence: Metric Monitoring
    http://blog.jinspired.com/?p=33
    There are also many low level memory inspection tools on the market that might help quickly navigate the heap and identify the problem though I think the JRA tool has probably most of the same features.
    Regards,
    William Louth
    JXInsight Product Architect
    CTO, JInspired
    "Java EE tuning, testing, tracing, and monitoring with JXInsight"
    http://www.jinspired.com

  • BUG:  Apex4/Anychart5 - memory leak?

    We are running into a pretty serious problem with resources. It seems that there is some kind of interaction between Apex and Anychart5 that is causing a pretty serious memory leak. For example, in one dashboard I am building, I have 9 charts on a page. When I click through a chart to a second page, I have three charts and an Interactive report.
    None of the sql is really all that complex. But I will include one of the queries singled out by one of our DBAs as being involved in consuming over 20 GB of data (values slightly modified for security). The query:
    SELECT CASE
    WHEN quarter = 'Q1'
    THEN
    '/pls/apex/f?p=108:3:1111111111111111::::P3_YEAR1,P3_YEAR2,P3_CLICK_VAL,P3_QUARTER:2009,2008,2009,1:'
    WHEN quarter = 'Q2'
    THEN
    '/pls/apex/f?p=108:3:1111111111111111::::P3_YEAR1,P3_YEAR2,P3_CLICK_VAL,P3_QUARTER:2009,2008,2009,2:'
    WHEN quarter = 'Q3'
    THEN
    '/pls/apex/f?p=108:3:1111111111111111::::P3_YEAR1,P3_YEAR2,P3_CLICK_VAL,P3_QUARTER:2009,2008,2009,3:'
    WHEN quarter = 'Q4'
    THEN
    '/pls/apex/f?p=108:3:1111111111111111::::P3_YEAR1,P3_YEAR2,P3_CLICK_VAL,P3_QUARTER:2009,2008,2009,4:'
    END
    link,
    quarter label,
    so_ext_price Sales_2009
    FROM ( SELECT SUM (v.so_ext_price) so_ext_price,
    ('Q' || TO_CHAR (v.cal_qtr_num)) quarter
    FROM owner.materialized_view_mv@db_link_name v
    WHERE v.cal_year = TO_CHAR (2009)
    AND v.account_number IN
    (SELECT *
    FROM TABLE(user_pkg.get_customer_numbers (
    'APP_USER',
    'USER_PROPERTY',
    'CUSTOMER_NAME'
    -- THE ABOVE SUBQUERY SELECTS FROM A PIPELINE FUNCTION TO RETURN A LIST OF STRINGS
    GROUP BY v.cal_qtr_num
    ORDER BY v.cal_qtr_num)
    As you would expect, this query returns 4 records reflecting sales by quarter. The query takes about four seconds to run. Explain plan cost is just under 14K. The pipeline function literally returns a single column of about six values using a simple select distinct where the parameters passed are filters in the where clause. The pipeline function returns in approximately 1 second. The largest result set it ever returns is six rows. The pipeline function is innocuous on its own but I am suspicious that it may be where we're running into issues. We weren't seeing these problems (or at least they weren't as noticeable) until we needed to use pipline functions. 'Don't use pipeline functions' is not an acceptable work around in our case. While I can figure out a way around it in the charts by returning SQL from a function, I cannot do so in the interactive reports.
    What our DBAs found is that the code pasted below is what was sucking down 22 GB of ram, then after clicking through to the second page the same code (for a different chart query) was consuming 17 GB of ram almost depleting our 48 GB of ram on our server in less than ten minutes. I disabled the chart running each 'offending' query and we had the same results with a different chart but the same underlying code below.
    I don't know where in Apex this lives but it's the killer. Can I get some feedback? Anyone else having similar issues?
    declare
    rc__ number;
    simple_list__ owa_util.vc_arr;
    complex_list__ owa_util.vc_arr;
    begin
    owa.init_cgi_env(:n__,:nm__,:v__);
    htp.HTBUF_LEN := 63;
    null;
    null;
    simple_list__(1) := 'sys.%';
    simple_list__(2) := 'dbms\_%';
    simple_list__(3) := 'utl\_%';
    simple_list__(4) := 'owa\_%';
    simple_list__(5) := 'owa.%';
    simple_list__(6) := 'htp.%';
    simple_list__(7) := 'htf.%';
    simple_list__(8) := 'wpg_docload.%';
    if ((wwv_flow_epg_include_modules.authorize('apex_util.flash') = false) or (owa_match.match_pattern(p_string =>
    'apex_util.flash'
    /* */,p_simple_pattern =>
    simple_list__
    ,p_complex_pattern =>
    complex_list__
    ,p_use_special_chars =>
    false)))
    then
    rc__ := 2;
    else
    null;
    null;
    apex_util.flash(p=>:p,XMLCallDate=>:XMLCallDate);
    if (wpg_docload.is_file_download) then
    rc__ := 1;
    wpg_docload.get_download_file(:doc_info);
    null;
    null;
    null;
    commit;
    else
    rc__ := 0;
    null;
    null;
    null;
    commit;
    owa.get_page(:data__,:ndata__);
    end if;
    end if;
    If we are barking up the wrong tree, I'd be VERY happy. I'd rather it was something I could fix.
    Edited by: WannaRock on Aug 24, 2010 9:53 AM

    Thanks for looking at this post. We have resolved the issue for ourselves by working with our DBAs to narrow down where the problem actually started. We found that the particular SQL we were looking at was not the issue. In a chart on a subsequent page (via a click through), we were actually running into where apex was starting to consuming memory but we were catching it later.
    What we found was that when we had a chart query that was SQL containing a pipeline function, the memory usage went up. And within 10 minutes, the server would crawl to a halt. To release the memory, the DBAs would have to bounce the Apex instance. When I changed the query to be a function returning SQL, the problem stopped. I don't know what the correlation was between SQL and moving to a PL/SQL function returning SQL.
    I am not even 100% positive of the pipeline function being the cause. I only know that this started happening about the same time as when I implemented the pipeline function. I understand you are leery of a one-second function/query running up that kind of utilization. No one here believed me either (including me really). We figured it HAD to be a coincidence. But once I changed the query from SQL to a function returning PL/SQL, our problem went away.
    Thanks to all who looked at and thought about this.
    Walter

  • Memory Leak in QTPlugin ? (QT7, and QT 6.5+)

    Trying to track this down, there is a problem with a memory leak when doing a endless loop quicktime sequence of images. To get the loop, I've created a SMIL file with the images, then have a HTML page that uses the EMBED tag to reference these SMIL files via QTNEXTxx, with a final GOTO0 to get back to the start.
    It works, but if you watch the process with Activity Monitor (or top) you can see that memory consumption grows over time and will eventually crash whatever browser you are using. This happens if I open the HTML file with Safari, iCab, Opera, Firefox, RealPlayer, etc...
    Very simple example with even one image will leak memory, albeit at a slower pace:
    HTML: (replaced brackets with curly braces)
    {html}
    {head}
    {title}radarLoops.html{/title}
    {/head}
    {body bgcolor="#000000"}
    {center}
    {embed src="file1.smil BGCOLOR="#000000" autoplay="true" controller="false" width="800" height="620" pluginspage="http://www.apple.com/quicktime/download/" QTNEXT1="GOTO0"}
    {/center}
    {/body}
    {/html}
    file1.smil:
    SMILtext{smil xmlns:qt="http://www.apple.com/quicktime/resources/smilextensions" qt:autoplay="true" qt:time-slider="false"}
    {head}
    {layout}
    {root-layout width="800" height="620" background-color="black" /}
    {region id="region_1" left="0" top="0" width="800" height="620" fit="fill" /}
    {/layout}
    {/head}
    {body}
    {seq}
    {img src="TEST.JPG" region="region_1" dur="1s" /}
    {/seq}
    {/body}
    {/smil}
    To workaround this issue, we had to revert to a 10.3.x system with QT6.4.x on it, reverting a 10.3.9 to QT6.5.x didn't work. A Tiger installation with 7.0.3 doesn't work either, it leaks like a sieve.
    How can I debug this?

    Write a main() that does the polling in a tight loop 1000 times. Then System.gc(); Thread.sleep(1000); System.exit(). Run the thing with -Xrunhprof. Observe the "live bytes" and "live objs" columns in the generated java.hprof.txt file. Anything that strikes as suspicious? If every polling round leaks one object, there's likely to be 1000 (or N*1000) of something live. Make sure the leak is in the polling routine by running it 1,000,000 rounds and getting an OutOfMemory.

  • Memory Leak in NK.exe

    Hi All,
    OS: Windows Embedded Compact 7 with updates till Feb 2015.
    Hardware: AM335x based 
    Applications running: one serial port application and one tcpclient and tcpserver apps. all are managed (C#) applications
    I am facing memory leak issue with our headless device. 
    When I connect the device to LAN network, memory usage keep increases and after few hour (some times <1 hour, some times 4-5 hour) devices go to hang state due to low memory.
    I also tried to run the resource leak detector and found
           1. NK.exe heap is increasing
           2. on startup : API Handle Count = 4118, DuplicatedHandle - Count : 4,082, Size : 4,082 bytes
    After few minutes: APIHandle - Count : 49,172, Size : 49,172 bytes, DuplicatedHandle - Count : 48,810, Size : 48,810 bytes
    NK.exe heap increases as available RAM decreases.
    our application heap is constant only. please find below memory snapshots taken by devhealth.
     1. On device start up after all apps started
    2. After 1 hour of device running. - refer attachment
     where exactly might be this leak, any Guess?
    Thank you...
    rakesh

    Hi tomleijen,
    Thanks for your suggestions.
    Even we tried without any user apps, then also we found ~1 MB increase in NK.exe heap every 30-40 min.
    we have 2 images 1. with all WEC7 updates (Till feb 2015) and 2. without any of the WEC7 updates
    almost same problem we are facing with both images.
    rakesh

  • Looking for memory leak in labview 6.02

    dear all,
    my labview program needs an increasing amount of memory when running (at the time about 12k/s) which leads to swapping memory on my hdd.
    i have found out that calling cluster references like Controls[] or decos[] leads to this kind of memory leak and made a work around for that (simply calling it only once at runtime) but there are more memory leak(s)which i cannot find. The bugs that i have found searching the labview resources does not answer my problem.
    does anybody already found out more memory leak problems ?
    thanks

    I have been seeing similar behavior; I too have not found all the
    leaks. I think I have slowed the allocation by replacing some of my
    'build array' functions with the combination of 'initialize array'
    followed by 'replace array subset'. The drawback to doing it this way
    is that you have a fixed maximum number of elements allocated just once
    rather than allowing an array to grow incrementally. Please let me know
    if you try removing build arrays and if that helps.
    By the way, there is a checkbox under the options menu to deallocate
    memory as soon as possible - if you don't mind that your program runs
    more slowly, this may help to avoid the problem, at least temporarily.
    -vinny
    ciossek wrote:
    > dear all,
    > my labview program needs an increasing amount of memo
    ry when running
    > (at the time about 12k/s) which leads to swapping memory on my hdd.
    > i have found out that calling cluster references like Controls[] or
    > decos[] leads to this kind of memory leak and made a work around for
    > that (simply calling it only once at runtime) but there are more
    > memory leak(s)which i cannot find. The bugs that i have found
    > searching the labview resources does not answer my problem.
    >
    > does anybody already found out more memory leak problems ?
    >
    > thanks

Maybe you are looking for

  • Problem connecting PowerPivot's (Office 2013) Data Model deployed on SharePoint 2013 to data source.

    Hello: Our configurations is as follow :  SharePoint 2013 is on Server A;  SQL Server Analysis server (SQL 2014) is on DB Server B;    SharePoint databases (sp_ ...) and our Data Mart (SQL 2014) are on server B. All servers runs Windows 2012 OS. On m

  • What is the best way to create a "to delete file" in iPhoto?

    I'm helping a friend downsize their library, but they want to be able to double check the photos before they get deleted. I realize that I cannot create a "to delete album" as this keeps the original still in the library.  My thought was to create a

  • RGB image coloured to spot colour

    We have supplied images (jpeg, tiff, wmf) that are RGB Black & White. I want to be able to place the image in a box and set the colour to a spot colour ie PMS 280. I can colour them up using Transparency>Lighten having set the background colour of th

  • How to recognize Oracle Patch in R12

    Hi, How do i identify if customer is a federal or Non federal. I checked the status of below two products and noticed that GHR is "Shared" , does that mean customer is a federal customer? APPLICATION_SHORT_NAME                             PATCH_LEVEL

  • Impact on using function modules that are flagged as obsolete

    Hi Gurus, I'm working on a SAP 4.7 instance and we are soon to be going Unicode enabled. I noticed when running transaction UCCHECK that there are a number of function modules such as "POPUP_TO_CONFIRM_WITH_MESSAGE" and "POPUP_TO_DECIDE" as well as o