Contour is hogging CPU after form activate

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
mweaver
Newbie
Newbie
Posts: 10
Joined: Tue Apr 08, 2003 4:00 am

Contour is hogging CPU after form activate

Post by mweaver » Wed Dec 01, 2004 7:21 pm

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.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Dec 02, 2004 9:55 am

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.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

mweaver
Newbie
Newbie
Posts: 10
Joined: Tue Apr 08, 2003 4:00 am

Post by mweaver » Fri Dec 03, 2004 11:13 pm

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).

Christopher
Site Admin
Site Admin
Posts: 1349
Joined: Thu Jan 01, 1970 12:00 am
Location: Riudellots de la Selva, Catalonia
Contact:

Post by Christopher » Tue Dec 07, 2004 1:02 pm

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.
Thank you!

Christopher Ireland (Steema crew)
Please be aware of the newsgroup archives:
http://www.teechart.net/support/search.php
http://groups.google.com
http://codenewsfast.com/

Thomas
Newbie
Newbie
Posts: 10
Joined: Thu Nov 25, 2004 5:00 am
Location: Calgary, Canada
Contact:

100% CPU and flicker when contour active

Post by Thomas » Tue Jan 11, 2005 8:05 pm

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.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Jan 14, 2005 7:54 am

Hi Thomas,

I have been able to reproduce it. I have included it on our defect list to be fixed for future releases.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

TeeNee
Newbie
Newbie
Posts: 9
Joined: Fri Nov 15, 2002 12:00 am

Build 1.1.1879.21176 Contour CPU hog

Post by TeeNee » Thu Jun 23, 2005 10:03 am

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?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Jun 23, 2005 11:45 am

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.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

TeeNee
Newbie
Newbie
Posts: 9
Joined: Fri Nov 15, 2002 12:00 am

Post by TeeNee » Thu Aug 04, 2005 9:46 pm

Yes it has been fixed in the latest release. Cheers.

Post Reply