WinCE6 stack leak issue

Hi,
I am trying to track down an memory leak that I have been working on for the past few weeks.  The leak seems to be coming from the stack.  We are creating a thread of 1MB stack, but the system is only allocating 64k.  My gut feeling is anything
beyond this 64k is being leaked.
After the thread is created, I am getting the context ( reset) - and it is only 64k out beyond the mem base.  It should be 1MB.  Does anyone know why this is the case?  If our stack usage goes beyond the 64k range, how can the memory be recovered
(freed)?
This is a kernel driver creating kernel threads.  The driver is loaded by the system and threads are created and exited on "init" and "deinit" IOCTL (DeviceIOControl) calls, respectively.
Thanks!

Hi Paul,
Thank you so much for the reply.  Yes, the real goal is to eliminate the leak.  Leaks are on the order of 150k to 200k, but only occur when the threads are exited - we do a mem snaps shot from test to test and do a diff between the 2 physical mem
sizes.  I have concluded the leak is coming from the stack by allocating a large char array (within a function so it's not static) in our library that is called into from the running thread - we see it grow the larger I make the array.
Here is my create thread.
nStackSize = 1024 * 1024;
m_hMyThread = CreateThread(NULL,nStackSize,(LPTHREAD_START_ROUTINE)MyThreadShell,(LPVOID)this,CREATE_SUSPENDED | STACK_SIZE_PARAM_IS_A_RESERVATION,NULL);
After this, we get the "reset context" and commit it all to RAM so we don't run into demand paging issues.  What's strange is the context is at 64k (not 1MB as I would have expected).  My suspicion is if we use more than that 64k, we
lose whatever goes beyond that.  Our threading design typically runs in Application space for CE5/WinMobile - but relies on LoadDriver.  Since this is  now a kernel only call in CE6, we made a kernel driver.
We are tracking our own Heap and cleaning it up on exit, so I don't suspect this is leaking.  Our library uses a lot of stack space and is why we allocate so much.
Some other points:  This same design ("driver" model) works fine in CE5/Windows Mobile.
Thanks!
BTW:  Here is some data... We are creating 2 threads, first size is 1MB and second is default (linker settings - which is 64k).
Windows Mobile:
AllocationBase=0x2a1a0000, m_pMyContext->Sp=0x2a29fee0
AllocationBase=0x2a2a0000, m_pMyContext->Sp=0x2a33fee0
Thread1 “my context” is 1MB out from AllocationBase.
Thread2 “my context” is 64KB out from AllocationBase.
WinCE6:
AllocationBase=0xd6d00000, m_pMyContext->Sp=0xd6d0fe90
AllocationBase=0xd60b0000, m_pMyContext->Sp=0xd60bfe90
Thread1 “my context” is 64KB out from AllocationBase. <- BAD
Thread2 “my context” is 64KB out from AllocationBase.

Similar Messages

  • PROXY.NLM Abend & Memory Leak issues

    Issue:
    1. BM39SP2 abends frequently
    2. Memory Leak issue.
    3. During the restart, it has Short Term memory issues
    Environment:
    Netware 6.5 SP6
    BorderManager 3.9 SP2 (with latest proxy.nlm)
    Server has 4 GB memory
    Additional Info: The server is patched with the latest TCP & Winsock patch for SP6.
    Latest Abend information
    Novell Netware, V6.5 Support Pack 6 - Internal Release
    PVER: 6.50.06
    Server BMMH01 halted Tuesday, 23 March 2010 10:57:37.119 am
    Abend 1 on P00: Server-5.70.06: Page Fault Processor Exception (Error code 00000000)
    Registers:
    CS = 0060 DS = 007B ES = 007B FS = 007B GS = 007B SS = 0068
    EAX = 1B8A5FFA EBX = 222E40A8 ECX = FFFFB5F6 EDX = 1B8A440A
    ESI = 1B8A4EB2 EDI = FFFFC73E EBP = 1B8A15E4 ESP = 8AE58E14
    EIP = 1195093C FLAGS = 00010012
    1195093C 385006 CMP [EAX+06]=?, DL
    EIP in PROXY.NLM at code start +000CC93Ch
    Access Location: 0x1B8A6000
    The violation occurred while processing the following instruction:
    1195093C 385006 CMP [EAX+06], DL
    1195093F 744C JZ 1195098D
    11950941 385007 CMP [EAX+07], DL
    11950944 7451 JZ 11950997
    11950946 83E908 SUB ECX, 00000008
    11950949 0508000000 ADD EAX, 00000008
    1195094E 83F908 CMP ECX, 00000008
    11950951 73CC JNB 1195091F
    11950953 0BC9 OR ECX, ECX
    11950955 7408 JZ 1195095F
    Running process: Server 11 Process
    Thread Owned by NLM: SERVER.NLM
    Stack pointer: 8AE58F60
    OS Stack limit: 8AE51020
    Scheduling priority: 67371008
    Wait state: 50500F0 Waiting for work
    Stack: 118CD415 (PROXY.NLM|PLD_ParseHTTPHeaders+435)
    --1B8A4EB2 ?
    --FFFFC73E ?
    --00000001 (LOADER.NLM|KernelAddressSpace+1)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000A6A (LOADER.NLM|KernelAddressSpace+A6A)
    --1327FA48 ?
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --1B8A15E4 ?
    --222E40A8 ?
    1191031B (PROXY.NLM|SSLLoginWithFormDataCallback+36B)
    --00000001 (LOADER.NLM|KernelAddressSpace+1)
    --222E40A8 ?
    --1B8A15E4 ?
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --8AE58E78 ?
    --8AE58EE4 ?
    1191DF79 (PROXY.NLM|tsw_ssl3_ReadRecord+239)
    --98994F6E ?
    --1560BD04 ?
    --1B8A15F0 ?
    1191DFD4 (PROXY.NLM|tsw_ssl3_ReadRecord+294)
    --1B8A15F0 ?
    --8AE58E78 ?
    --00000014 (LOADER.NLM|KernelAddressSpace+14)
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --3935A2FF ?
    --097478C7 ?
    --A1C483D4 ?
    --00000008 (LOADER.NLM|KernelAddressSpace+8)
    --00000014 (LOADER.NLM|KernelAddressSpace+14)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000001 (LOADER.NLM|KernelAddressSpace+1)
    --1B8A15F0 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000028 (LOADER.NLM|KernelAddressSpace+28)
    --222E40A8 ?
    --00000028 (LOADER.NLM|KernelAddressSpace+28)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --1327FA48 ?
    --222E40A8 ?
    11910D85 (PROXY.NLM|SSLRedirectDataCallback+235)
    --222E40A8 ?
    --00000028 (LOADER.NLM|KernelAddressSpace+28)
    --8AE58EE4 ?
    --00000003 (LOADER.NLM|KernelAddressSpace+3)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --898E039B ?
    --00000001 (LOADER.NLM|KernelAddressSpace+1)
    --00000028 (LOADER.NLM|KernelAddressSpace+28)
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --222E40A8 ?
    --00000017 (LOADER.NLM|KernelAddressSpace+17)
    --00000001 (LOADER.NLM|KernelAddressSpace+1)
    --1B8A15E4 ?
    --00004800 (LOADER.NLM|KernelAddressSpace+4800)
    --222E40A8 ?
    119078CD (PROXY.NLM|TSW_SSL_Read+2D)
    --1560BD04 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --1B8A15E4 ?
    --1B8A15F0 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --0000000C (LOADER.NLM|KernelAddressSpace+C)
    --1B8A15E4 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --222E40A8 ?
    1190EF88 (PROXY.NLM|SSL_V3_ServerDataReplyHandler+158)
    --222E40A8 ?
    -1197D604 (PROXY.NLM|rsSSL_V3_ServerWaitingForRequest+0)
    --1560BD04 ?
    --222E40A8 ?
    --0347E701 ?
    --0F78E700 ?
    118E9400 (PROXY.NLM|CallrsCallBacks+0)
    118E9454 (PROXY.NLM|CallrsCallBacks+54)
    --222E40A8 ?
    00362862 (SERVER.NLM|StartWorkToDo+23)
    --222E40A8 ?
    --0347E701 ?
    --0F78E700 ?
    --8AE18E30 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    0021459A (SERVER.NLM|WorkerThread+4F6)
    --222E40A8 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --8ADA5400 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --8ADA5400 ?
    00221528 (SERVER.NLM|TcoNewSystemThreadEntryPoint+40)
    --8ADA5400 ?
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    --00000000 (LOADER.NLM|KernelAddressSpace+0)
    Additional Information:
    The CPU encountered a problem executing code in PROXY.NLM. The problem may be in that module or in data passed to that module by a process owned by SERVER.NLM.
    Kindly suggest.

    In article <[email protected]>, Dkeyur wrote:
    > Netware 6.5 SP6
    > BorderManager 3.9 SP2 (with latest proxy.nlm)
    > Server has 4 GB memory
    >
    > Additional Info: The server is patched with the latest TCP & Winsock
    >
    Is the above correct? If so, you are not even close to having the
    latest patches. (NW65SP8, not SP6). Adding late tcp and winsock
    patched to SP6 would probably cause problems.
    If you look over the abend messages, and some of them refer to an LSL
    component, it's very likely you need the wsock6o patch. (Check tip #1
    at the URL below).
    If you just typo'd the patch, and you are at sp8, at least try clearing
    the cache. Unload proxy, load proxy -cc.
    Craig Johnson
    Novell Knowledge Partner
    *** For a current patch list, tips, handy files and books on
    BorderManager, go to http://www.craigjconsulting.com ***

  • Memory leak issue on Blackberry Torch 9860

    I own a Blackberry Torch 9860 Os 7.0 Bundle 1465 for the last 5 months
    Previously I had Blackberry Curve 9300 which I had upgraded to OS 6.0. It had memory leak issues wherein my application memory would gradually dropdown to merely KBs within a few days and I had to reboot it to restore the same.
    When I purchased Torch 9860, I migrated my device settings from Curve to Torch using the Desktop Manager. I face the same memory leak issues in this new device as well. I have 3 email accounts configured on my device and some social networking applications which include facebook, twitter, and some messengers. I usually delete my emails and keep only a few useful mails for reference. Still I am facing this issue wherein I have to reboot my device to restore the application memory. It starts from 152 Mb and usually dropsdown to merely Kilobytes of memory. The phone freezes for around 1-2 minutes sometimes when I am on call, or accessing my contacts.
    Also to let you know that I have a 8GB memory card on my phone which has around 1.6 GB free space. I have disabled Compression on my memory card as well.
    Please advise as I am having a hard time using this time this way.
    Regards,
    Abhinav Sharma
    Thanks and regards,
    Abhinav Sharma

    I have the almost same problem when i run the phone gap app on the 9800 torch OS 6 than this build of 1.2 MB takes the memory of 40 MB at run time and the device gives the low memory message and close the app forcefully.
    In my app phone gap is using 3-4 html pages and java script .
    And when i navigate on these pages it gives this message of memory low.
    Please help me to out of this .
    And please suggest if any professional help in this
    Thanks\\\
    Vipin Tomer

  • Memory leak issue with link server between SQL Server 2012 and Oracle

    Hi,
    We are trying to use the linked server feature with SQL Server 2012 to connect SQL server and Oracle database. We are concerned about the existing memory leak issue.  For more context please refer to the link.
    http://blogs.msdn.com/b/psssql/archive/2009/09/22/if-you-use-linked-server-queries-you-need-to-read-this.aspx
    The above link talks about the issues with SQL Server versions 2005 and 2008, not sure if this is still the case in 2012.  I could not find any article that talks about if this issue was fixed by Microsoft in later version.
    We know that SQL Server process crashes because of the third-party linked server provider which is loaded inside SQL Server process. If the third-party linked server provider is enabled together with the
    Allow inprocess option, the SQL Server process crashes when this third-party linked server experiences internal problems.
    We wanted to know if this fixed in SQL Server 2012 ?

    So your question is more of a information type or are you really facing OOM issue.
    There can be two things for OOM
    1. There is bug in SQL Server which is causing the issue which might be fixed in 2012
    2. The Linked server provider used to connect to Oracle is not upto date and some patch is missing or more recent version is to be used.  Did you made sure that you are using latest version.
    What is Oracle version you are trying to connect(9i,10g, R2...)
    Please mark this reply as answer if it solved your issue or vote as helpful if it helped so that other forum members can benefit from it
    My Technet Wiki Article
    MVP

  • Process memory leak issue  solaris 10

    I have a process which has a memory leak issue. I ran this process on solaris 9 as well as solaris 10. When i run prstat command i get a different output for two. Funny thing is that memory leak noted in solaris 10 is much more than that in solaris 9 e.g if it is 1 MB in solaris 9 then its 4 MB in solaris 10.
    What can be possibly causing this ? Is this related to kernel implementation on diff solaris ?

    I have a process which has a memory leak issue. I ran this process on solaris 9 as well as solaris 10. When i run prstat command i get a different output for two. Funny thing is that memory leak noted in solaris 10 is much more than that in solaris 9 e.g if it is 1 MB in solaris 9 then its 4 MB in solaris 10.
    What can be possibly causing this ? Is this related to kernel implementation on diff solaris ?

  • What is the best way to deal with memory leak issue in sql server 2008 R2

    What is the best way to deal with memory leak issue in sql server 2008 R2.

    What is the best way to deal with memory leak issue in sql server 2008 R2.
    I have heard of memory leak in OS that too because of some external application or rouge drivers SQL server 2008 R2 if patched to latest SP and CU ( may be if required) does not leaks memory.
    Are you in opinion that since SQL is taking lot of memory and then not releasing it is a memory leak.If so this is not a memory leak but default behavior .You need to set proper value for max server memory in sp_configure to limit buffer pool usage.However
    sql can take more memory from outside buffer pool if linked server ,CLR,extended stored procs XML are heavily utilized
    Any specific issue you are facing
    Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers

  • Has anyone found a solution for iPhone 5 data leak issues?

    Up until about a week ago I was using a 3GS and the data leak issues seemed to be fixed with the newest iOS 6 update. However, I recently got an iPhone 5 and I've noticed it uses around 1 MB per hour no matter what I'm actually doing on the phone. I actually went to sleep last night, turning of cellular data AND wifi and it STILL used about 4 MB of data!! What is up with this?? I am a pretty conservative user of data when not on wifi, but I'm only 2 days in to my bill cycle and already on pace to go over my 2 GB limit by the end of the month. Please help! I do not want to switch my plan and play more! I am on AT&T by the way.

    Have you tried these basic troubleshooting steps?
    Restart / Reset
    http://support.apple.com/en-us/HT201559
    Restore from backup
    Restore as new
    http://support.apple.com/en-us/HT201252
    If no joy, make an appointment with the Apple genius bar for an evaluation.

  • Is this a memory leak issue ?

    We are using Jdev10g + BC4J + Struts + JSP to build our enterprise application,
    but when the application running some days in our Application Server(RedHat AS3-86, with 4GB RAM), the memory consumed is serious ! we doubt and worry
    about maybe our application suffer the memory leak problem, so we want to know have the command to find out whether our application caused the memory leak
    issue and which program is the major murderer for memory.
    In EM console , the memory utilization chart have big memory consumed in "other" legend ? the "other" legend is mean what ? I cannot find the consumer process in system level through ps command ? it seems disapear ! but after I reboot the server , the "other" legend is clear !

    The second scenario is, as we perform some deployment activity on 10g, the memory usage chart shows a sharp consumption of memory about 1.5GB .the loss memory almost be display in "other" legend chart !
    Please give us some advice , thanks in advance

  • PGA memory Leak issue along with TNS: listener could not hand off client connection

    Hi,
    We have two Oracle Database instances in a 32 bit Standard Edition Windows OS machine with 3 GB RAM : 1) 1525 MB (SGA+PGA) 2) 515 MB (SGA+PGA)
    Recently we upgraded the RAM from 3 GB to 4 GB. Subsequently we upgraded the SGA + PGA of the 2nd instance to 771 MB.
    This has resulted into PGA memory leak issue reported in the alert log file and trace file.
    Reverting back the SGA+PGA size to 515 MB solved the issue.
    Is this issue related to Address Windowing Extension (AWE)?
    Is the reason related to Total memory for all the cumulative Oracle instance should be < 2GB.
    How to solve this?
    Mon Jul 15 08:21:25 2013
    ORACLE V10.2.0.4.0 - Production vsnsta=0
    vsnsql=14 vsnxtr=3
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Windows Server 2003 Version V5.2 Service Pack 2
    CPU                 : 4 - type 586, 4 Physical Cores
    Process Affinity    : 0x00000000
    Memory (Avail/Total): Ph:1068M/4023M, Ph+PgF:4985M/7933M, VA:18M/2047M
    Instance name: dp3
    Redo thread mounted by this instance: 0 <none>
    Oracle process number: 0
    Windows thread id: 4484, image: ORACLE.EXE (SHAD)
    *** 2013-07-15 08:21:25.133
    *** ACTION NAME:() 2013-07-15 08:21:25.133
    *** MODULE NAME:() 2013-07-15 08:21:25.133
    *** SERVICE NAME:() 2013-07-15 08:21:25.133
    *** SESSION ID:(90.829) 2013-07-15 08:21:25.133
    ******** ERROR: PGA memory leak detected 6302928 > 30176 ********
    HEAP DUMP heap name="pga heap"  desc=6C98A800
    extent sz=0x206c alt=92 het=32767 rec=0 flg=3 opc=3
    parent=00000000 owner=00000000 nex=00000000 xsz=0x0
    EXTENT 0 addr=7FC10008
      Chunk 7fc10010 sz=    64996    free      "               "
      Chunk 7fc1fdf4 sz=  2097676    freeable  "krfrbAllocate: "
    Dump of memory from 0x7FC1FDF4 to 0x7FE20000
    7FC1FDF0          1020020D 7FC10010 03871E90      [.. .........]
    7FC1FE00 00000000 00000000 00000000 00000000  [................]
      Repeat 131103 times
    EXTENT 1 addr=7FA00008
      Chunk 7fa00010 sz=    64996    free      "               "
      Chunk 7fa0fdf4 sz=  2097676    freeable  "krfrbAllocate: "
    Dump of memory from 0x7FA0FDF4 to 0x7FC10000
    7FA0FDF0          1020020D 7FA00010 03871E90      [.. .........]
    7FA0FE00 00000000 00000000 00000000 00000000  [................]
      Repeat 131103 times
    EXTENT 2 addr=7F7F0008
      Chunk 7f7f0010 sz=    64996    free      "               "
      Chunk 7f7ffdf4 sz=  2097676    freeable  "krfrbAllocate: "
    Dump of memory from 0x7F7FFDF4 to 0x7FA00000
    7F7FFDF0          1020020D 7F7F0010 03871E90      [.. .........]
    7F7FFE00 00000000 00000000 00000000 00000000  [................]
      Repeat 131103 times
    EXTENT 3 addr=70A50008

    There may be something fixed in the patch that gives the error rather than mysterious hangs.  I would prefer that, myself.  There may be something in the patch that changes how Oracle allocates user, system and program areas.
    At some point you spend more trying to limp things along in a growing environment than simply upgrading.  32 bit environments these days is an indicator that management is figuring some false economies.  But that's their prerogative.
    The PGA can be affected by many things, not least of which is how the application uses it.  Much has been written about it, my own experience has been more is used than most people say.  But that is probably just my app.  Note there are different ways to set it, and a parameter with "target" in it might not be a hard limit.  Different execution plans for the same code may use different amounts of memory - there can even be situations where forcing some code to use a sort area instead, or even forcing more operations to disk, can free up more pga for everyone else.  It depends.  But that's why I look at multi-pass operations in dbconsole.

  • Memory Leak issues

    Hello. I am having an issue with Flash 9 and wasnt sure if
    this needed to be posted in here or general. I figured that I would
    need some kind of code to fix this so I posted it in here.
    This is my issue..the typical dreaded memory leak problem.
    The project looks very similar to this:
    We have, say, 100 individual images in the library. Each
    image is an 800x600 jpg file. We create a layer and put each image
    on a frame. About every so many frames, (lets say frame 33 or frame
    66) we stop at that point and ask a question and wait for some kind
    of response from the user. If its the correct response, we continue
    on, if not, we just repeat the question till they get the answer
    correctly. There are also fscommands that send out to an external
    application if the user clicked the correct or incorrect answer at
    these points.
    However, this is causing a rather massive memory leak. I was
    wondering if there is a solution either by code or we are just
    doing something wrong, to help fix our memory leak issue. Some
    files in our projects are small enough to not notice it but we have
    one particular file that is around 500 frames of animation and you
    can imagine how hungry flash got with this one.
    Any suggestions?

    Lots of ideas:
    First thing? Check the File Free at Options > Status, what is the number at File Free? Now, remove the battery of your device, hold a minute, replace and reboot. What is the File Free now?
    Read this: http://www.blackberryforums.com/general-blackberry-discussion/116396-managing-your-bb-memory-lost-ca...
    And this: http://www.blackberryforums.com/general-blackberry-discussion/112029-losing-call-logs-sms-emails-opt...
    Additional links to read:
    http://www.blackberry.com/btsc/search.do?cmd=displayKC&docType=kc&externalId=KB15345&sliceId=SAL_Pub...
    http://www.blackberry.com/btsc/search.do?cmd=displayKC&docType=kc&externalId=KB14320&sliceId=SAL_Pub...
    http://www.blackberry.com/btsc/dynamickc.do?externalId=KB14213&sliceId=SAL_Public&command=show&forwa...
    1. If any post helps you please click the below the post(s) that helped you.
    2. Please resolve your thread by marking the post "Solution?" which solved it for you!
    3. Install free BlackBerry Protect today for backups of contacts and data.
    4. Guide to Unlocking your BlackBerry & Unlock Codes
    Join our BBM Channels (Beta)
    BlackBerry Support Forums Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • Reporting security-related stack overflow issue

    How should I report a potentially security-related stack overflow issue that I encountered that lead to a QuickTimePlayer crash?

    The most certain way to report a true bug (as opposed to a comment or feature request) is to sign up as an Apple Developer - the online membership is free - and report the bug through the bug reporter.
    Otherwise, report it through the QuickTime Feedback page.
    Regards.

  • Need help with an Aforge and windows forms memory stack-up issue

    Hello,
    I am experiencing a strange memory stack-up in my c# windows form program that occurs all the time on slow PCs, and when the windows form loses focus or is otherwise interrupted on faster PCs.
    The program I have written uses Aforge to get images from my webcam, which I then display in an Aforge picturebox control (CurrImagePic in code) in the windows form.  The images are switched into the picture box and then disposed at the camera's native
    framerate, so it appears as video to the user, not still images.  The picture box is 1080x1920, but the space for it in the form is smaller and so I allow the user to scroll around the picture.
    After about ~30 seconds of memory-stable operation on slower PCs, the problem begins.  On faster PCs, the problem only occurs when holding down scroll bar arrows or clicking and dragging around either scroll bar, and if I lock the PC or bring up the
    Ctrl+Alt+Delete menu.
    The problem itself is that memory used by the program starts to increase in very large chunks, leading to an out of memory crash.  This is unstoppable on slower PCs, but on the faster PCs if you stop scrolling or return from the lock/Ctrl+alt+delete
    menu, the program stabilizes at the higher memory usage level.  The memory that was accrued during scrolling or while in the lock menu is never collected by the garbage collector.  I've even tried to put in a button that forces a GC.collect() when
    pressed, and it does not reduce this memory usage.
    I've run perfmon and found that the memory increase is on the unmanaged heap, but I don't know if it's coming from bitmaps which are not being disposed or what it could be from.  It's been impossible to track down since it does not occur except in the
    above conditions.  I've tried various solutions (like moving my image processing out of the event handler and even using both global flags and a "lock" statement to try and ensure that only one thread or frame can access the image processing
    and displaying method at at time, but I have seen no change.  In fact, I am now seeing some unexplained small jumps in memory usage that I wasn't seeing before I put in the lock and moved the processing out of the handler.
    Has anyone run into situations like this?  I am at a loss for what I need to fix.  I think the problem is based around my Aforge event handler and image processing method if it is in my code at all - but I also have a suspicion that this is something
    deeper in the windows form code that I am either misusing or that can't keep up with the demands of my code.  Code below:
    //Applicable Globals to this code snippet
    private bool ALLOWFRAME = true;
    private Object FRAMEKEY = new Object();
    private VideoCaptureDevice COMPVID;
    private Bitmap TMPLTCAP;
    private System.Drawing.Image OLDIMAGE;
    private bool RCRDPIC = false;
    private void COMPVID_NewFrame(object sender, NewFrameEventArgs eventArgs)
    //Only process a frame when another is done processing
    if (ALLOWFRAME == true)
    ALLOWFRAME = false;
    Bitmap PassFrame = AForge.Imaging.Image.Clone(eventArgs.Frame);
    ProcessFrame(PassFrame);
    PassFrame.Dispose();
    private void ProcessFrame(Bitmap frameIn)
    lock (FRAMEKEY)
    if (OLDIMAGE != null) { OLDIMAGE.Dispose(); }
    //Call comparison method if flag is set.
    if (COMPON == true)
    Difference TmpltFilter = new Difference(TMPLTCAP);
    TmpltFilter.ApplyInPlace(frameIn);
    OLDIMAGE = CurrImagePic.Image;
    CurrImagePic.Image = AForge.Imaging.Image.Clone(frameIn);
    OLDIMAGE.Dispose();
    else
    OLDIMAGE = CurrImagePic.Image;
    CurrImagePic.Image = AForge.Imaging.Image.Clone(frameIn);
    OLDIMAGE.Dispose();
    //Toggle the flag back to false to show it's safe (i.e., comparisons have stopped)
    //for the result-recording method to copy from the picture box if it is attempting to copy
    if (RCRDPIC == true)
    RCRDPIC = false;
    ALLOWFRAME = true;

    As you are using third party tools and controls, and I cannot find posts on parallel cases using native VS controls, have you asked in the Aforge forums about your memory issue?
    http://www.aforgenet.com/aforge/framework/

  • Memory Leak Issue in OBIEE 11g

    Hi,
    We have OBIEE 11.1.1.5 installed on a 32-bit Windows Server. We had almost 10GB of free space yesterday, but after a few users logged in, the free space started coming down until we were left with no space at all.
    Since then we have removed all the files that we could and created more and more space, but OBIEE seems to be eating it all up. I have seen a few posts for such issues with the Linux Systems. Has anyone faced this with windows? Also, is there any solution for this.
    Thanks,
    Naman

    Hi Naman,
    Oracle has provided set of patches to avoid memory leaks.
    1) For memory leak with OPMN, apply the following patches:
    Patch:12920592: OPMN HAS MEMORY LEAK
    Patch:12989751: OPMN MEMORY STILL GAINS AFTER APPLYING PATCH#12920592
    2) For the Presentation Server (sawserver) issue, apply the patch:
    Patch:13102881: DATALAYOUT METADATA IMPLEMENTATION HEAP INTENSIVE
    Rgds,
    Dpka

  • Memory Leak issue 1.5.4.59.40-no-jre  jdk1.6.0_12  jre6

    Me and 2 other develops have been using SQL developer since it was created but we are getting really frustrated with the memory leaks we are experencing.
    We will start up sql developer and if we just leave it alone within a couple hours it will have taken up 650Megs of ram and be completely locked up. If we are working in sql developer the time can be even faster till it lockups up. We have been experencing the issue for very long time but seems to have gotten worse in the last to updates.
    I have tried to search the web and form for information to the memory problem to no avail. We are running oracle 10g and windows XP with 2gigs of ram.
    Can some one point me to some information or have any idea what is going on?
    Edit--
    I just realized that I was not using the latest version that I have downloaded. Trying sqldeveloper-1.5.4.59.40-no-jre will advise as to results.
    Edited by: ObeTheDuck on Mar 17, 2009 8:47 AM
    2nd Edit--
    1.5.4.59.40-no-jre has the same issue. 2hrs and it has locked up and is no longer listed as a running app and can only be seen under the process thread in windows task manager with 50% CPU use on a dual-core cpu and 626megs ram being used. Have to kill and restart ... <sigh>
    Edited by: ObeTheDuck on Mar 17, 2009 10:45 AM

    Thanks for the info so far....
    We really do like sql developer as a tool and has been execeding helpful and useful as our development tool.
    I am proud to say we have been using it since the 2nd month is was available and have been encourged and happy with most of the improvements.
    I am looking forward to trying the modeling tool soon.
    If I can get back to having a stable work enviorment for a work day that will be fine for now. It's just been reduced down to 2hrs which is a bit much.
    Anyway...
    1. We don't have any in house extentions that we need. I am speaking of the one that come bundled with the tool. Or at least I thought that they came bundled.
    Several are migration tools which we don't need. One is TenTime tool which I don't think we need.
    Last is the versioning extention, this sounds like something we want to use, but stability is more important at the moment. So unchecked they have all been.
    2. Sue you asked about a clean install. Is that simply an unpacking a new folder copy and then not migrate settings when running?
    3. I will be glad to uninstall java a switch to different version of the jdk which one is consider to be the most stable atm?
    Thanks,
    Obe

  • Memory leak issue with static basicWriteLockInfo

    Hi,
    I am using JE 3.3.69 and am seeing a memory issue that I do not see with JE 3.2.76. The application loads the database (filling the DB cache in the process), fully closes the environment, re-opens the environment, and then preloads databases until the DB cache of the new environment is full. What seems to be happening is that the the DB cache from the closed environment is never garbage collected and the preload causes an out-of-memory error since the heap is not big enough for two full caches.
    I saw that there is a static field in WriteLockInfo referencing a database (through the abortDb field) and is thereby holding on to the objects that make up the DB cache of the closed environment.
    static final WriteLockInfo basicWriteLockInfo =
         new WriteLockInfo();
    Should this static field belong to the environment instead?
    Is there a work-around I can try?
    Thanks,

    This bug, or something very similar, still exists for databases using the shared cache.
    The whole shared cache ends up leaked.
    I don't know what is causing the leak, and if it is the same or similar internal cause as the previous bug.
    I can confirm that for databases using their own (non-shared) cache, it no longer occurs but did in the past.
    Reproduction:
    Open Environment A (large) with locking disabled, using the shared cache, set the cache to a known percent value.
    Open Environment B, C, D, etc in the same shared cache
    Access Environment A until a large amount of RAM is used by the cache. Stop activity. Garbage Collect. Note remaining heap size (JConsole, Jstat, JMX, various other ways).
    Open Environment A2 (same thing, different dir -- in our case we are swapping out updated data).
    Close Environment A. Garbage collect -- no difference in size. Note, A2 has not been accessed at all.
    Access Environment A2 again causing more memory to be used. It will grow well past its previous level above.
    Open Environment A3.
    Close Environment A2. Garbage collect -- it will free up all the stuff associated with A2, but all the stuff from A still remains.
    The effect is as if the first shared lru cache is lost. Repeated opening and closing recycles the memory properly. But whatever is accessed in the "first" opening is lost forever.
    When you use a cache that is 40% of the heap size (3500MB heap) and you lose 40% of the heap, its bad.
    We are unable to use the shared cache feature due to this bug, though we are thinking about investigating a purposeful open/access/close upon startup to work around it.

Maybe you are looking for

  • How to delete all Messages in B1-Event-Monitor

    Hello, is there a way to delete all Messages from the B1-Event-Monitor. Now we have: ... But when I try the "Delete All" Function nothing happend, and the Browser hang. I found this post.B1if db unexplained growth.. and followed all steps. 1)Monitori

  • ICloud Password in Mail Problem

    Why does mail keep asking the following: Enter password for account iCloud. The iCloud IMAP server "p07-imap.mail.me.com" rejected the password for user. What is this all about, why and how can it be solved? thanks

  • Motion 5 to Final Cut 7 Import Problems

    Hello! I am driving myself nuts with a project mixing Motion 5 with Final Cut Pro 7. I am using 1920 x 1080p settings in both programs with 23.98 frame rate settings in both. When I export from Motion (as either an image sequence or a self-contained

  • InDesignServer Service not starting on Windows Server 2003 (32bit & 64 bit)

    Note: this issue is different from this thread on a similar issue. This problem has plagued me for weeks and I finally give up. InDesign Server installs successfully and the InDesignServerService starts, but the server does not run. I can only run th

  • INTEGRATION_DIRECTORY_HMI rfc returning error 403

    Dear Experts, I have installed SAP Netweaver 7.4 PI server on windows and MS sql 2012. i have below issues which i could not get proper solution 1)RFC INTEGRATION_DIRECTORY_HMI returning error as 403: forbidden . This RFC is pointing to /dir/CacheRef