Page 1 of 1

Contour is hogging CPU after form activate

Posted: Wed Dec 01, 2004 7:21 pm
by 8119852
I found an interesting bug in TeeChart v1.1.1769.19457.

I first thought the bug was something in our code, but then I did a test using Steema's "ExecutableDemo" and the same thing happened. That leads me to believe it is a bug in TeeChart.

I am using the latest version of TeeChart (v1.1.1769.19457) and I am running on Windows Server 2003 with .NET Framework v1.1 SP1.

Here is how to reproduce the situation:

- start Windows Task Manager, and sort by CPU descending (So those processes with the highest CPU usage are listed at the top).

- start some other windows app (I was able to reporoduce the problem using both Windows Explorer and MSN Messenger)

- start TeeChartNetExamples.exe

- click on the 'All Features' tab, then expand 'Chart Styles\Extended\Contour'

- click on the "2D drawing"

- in the task bar, click on the other windows app so it becomes active

- now, while watching Task Manager, click on TeeChartNetExamples.exe in the task bar so it becomes active. The app is activated - but look at the CPU usage. It consumes approximately 50% of the CPU and continues to do so (I let it run for several seconds and it never stopped ...)


This doesn't appear to happen with any other style - only the Contour style. I'm not sure what is going on, but it appears that the Contour style is doing something when the form is activated - something that is hogging the CPU and stalling the process.

Posted: Thu Dec 02, 2004 9:55 am
by narcis
Hi mweaver,

We can only reproduce it the first time running the TeeChartNetExamples.exe application and it only lasts for some seconds until the CPU usage goes back to normality.

The cause for this may be the .NET Framework "cleanning" the objects.

Posted: Fri Dec 03, 2004 11:13 pm
by 8119852
I disagree. I don't think you can say this is .NET garbage collection. Here are the reasons that I don't believe this is a .NET garbage collection issue:

- The CPU only goes back to normal if the TeeChartNetExamples.exe is no longer active. As long as the *.exe remains active, it hogs the CPU at at least 50%. I tested on a different machine and it was over 90%.

- It is only the Contour series that has this problem. The other series do not have this problem. If it were a .NET issue, it could happen with any series, but it reliably occurs with the Contour series and not with any other series.

- I used Performance Monitor to watch the process while it was hogging the CPU. The ".NET CLR Interop" monitor shows that the '# of marshalling' continues to grow rapidly as long as the process is active. Without any user interaction whatsoever, the # of marshalling continues to grow rapidly - into the thousands, tens of thousands, hundreds of thousands. Something is going on inside the Contour series. For some reason it is making repetitive COM Interop calls (that result in the continual marshalling). None of the other series do this - the # of marshalling is static once the series has been drawn. But the Contour series continues to do marshalling as long as the form is active (after being re-activated).

Posted: Tue Dec 07, 2004 1:02 pm
by Chris
Hi,
I found an interesting bug in TeeChart v1.1.1769.19457.

I first thought the bug was something in our code, but then I did a test using Steema's "ExecutableDemo" and the same thing happened. That leads me to believe it is a bug in TeeChart.

I am using the latest version of TeeChart (v1.1.1769.19457) and I am running on Windows Server 2003 with .NET Framework v1.1 SP1.
Well, I haven't been able to reliably reproduce the error using the steps you specified although I have been able to reproduce a similar error by adding a contour series into the chart at designtime, using Alt-Tab to move to another open Windows application and then Alt-Tab back to VS.NET.

I have added this error to the list of defects for the TeeChart for .NET and as such a fix for this error will be considered for inclusion into a future maintenance release.

100% CPU and flicker when contour active

Posted: Tue Jan 11, 2005 8:05 pm
by 9340003
I came here to read about the ill effect of contour series, although my experience is in Delphi 7 with TeeChart 7.02 Pro.
First an application written in D7/TeeChartPro601 showed contours perfectly, but the same code fails to show contours after moving to 702.
Then I found that a new application with a contour series added at design time flickers (and uses 100% CPU). After a few modifications in the chart editor the whole IDE freezes.

Posted: Fri Jan 14, 2005 7:54 am
by narcis
Hi Thomas,

I have been able to reproduce it. I have included it on our defect list to be fixed for future releases.

Build 1.1.1879.21176 Contour CPU hog

Posted: Thu Jun 23, 2005 10:03 am
by 8120845
I have TeeChart.NET Version 1 Build 1.1.1879.21176
and Contour CPU hog bug still has not been fixed :cry:

This bug has been around for a long time and I guess with V2 out now it will never be fixed. Is this right? Has it been fixed in V2?

Posted: Thu Jun 23, 2005 11:45 am
by narcis
Hi TeeNee,

You're right, it hasn't been fixed for the last version available, however we have fixed it for the next v1 maintenance release which is expected to be released during next week's first half. It is already fixed in v2 last available release.

Posted: Thu Aug 04, 2005 9:46 pm
by 8120845
Yes it has been fixed in the latest release. Cheers.