Page 1 of 1

CPU Usage Hangs

Posted: Tue Jun 10, 2008 5:18 pm
by Ken Alexander
We have an application that is a mix of VB6 and VB.NET. At unpredictable times the client machine's CPU Usage will jump to between 25% and 90% and stay there or climb until the application is shut down. Is this a memory leak? I am trying the Memory Profiler to see if it helps me find the problem. I am not very familar with GCing and memory usage. What would I look at in the Profiler to imediately tell me there is a serious memory leak. Any help would be greatly appreciated.

Thanks.

Posted: Fri Jun 13, 2008 1:32 pm
by Andreas Suurkuusk
High CPU usage is not normally an indicator of a memory leak, unless the memory leak causes an excessive amount of gen #2 collections. A memory leak can cause a lot of paging, which will cause the program to run very slow, but this should not cause high CPU usage.

To detect a memory leak you can run your application under the profiler and collect a few snapshots. If the total amount of live bytes increases in each snapshot, it indicates that you might have a memory leak.

Posted: Fri Jun 13, 2008 8:32 pm
by Ken Alexander
Thank you. I will keep looking.