We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpPrograms › Performances differences
Page Index Toggle Pages: 1
Performances differences (Read 739 times)
Performances differences
Jan 24th, 2006, 12:30pm
 
I have a script that don't do anything in the draw method, and a framerate of 30.

On a P4 3GHz the CPU is used at 100%
On my motebook (celeron 1.2GHz) the CPU is very low.

How can it be?

Thanks you for your help
Re: Performances differences
Reply #1 - Jan 24th, 2006, 5:11pm
 
there are some strange quirks about this but it's not worth it to worry about it unless it's actually affecting a real sketch. a sketch with an empty draw() method is a hypothetical and not really worth debugging for.
Re: Performances differences
Reply #2 - Jan 31st, 2006, 2:57pm
 
In fact it is acutally affecting a real sketch. I discover this strange things while trying to improve the performances. I was deleting one by one each action of the main loop to discover which one was guilty. And then I got an empty loop and the CPU was still 100% used Sad . The JRE installed for the computer where the sketch is very slow is "JRE 1.5.0_01 Java HotSpot".

I will post the JRE of my notebook when I'm at home.
Re: Performances differences
Reply #3 - Jan 31st, 2006, 3:41pm
 
processing will use as much cpu as is available, unless you tell it not to. if you don't want it to, set the framerate, or use noLoop() when you want the looping to stop.

we don't recommend java 1.5 if it can be avoided:
http://processing.org/faq/platforms.html#java
Re: Performances differences
Reply #4 - Jan 31st, 2006, 8:55pm
 
In the 2 cases, the framerate was set to 30 frames/seconds.

The JRE on my notebook is JRE 1.5.0_06. Maybe SUN has made a correction in this JRE since the JRE 1.5.0_01? I wil check this tomorrow, installing the JRE 1.5.0_06 on my computer.
Re: Performances differences
Reply #5 - Feb 1st, 2006, 10:33am
 
Hum, it's really strange.
Now the 2 computers have the same JVM (1.5 update 6) and the CPU is still used at 100% (frame rate 30) and nothing to do in the main loop...

I have the same problem on my home computer, and my office computer. Only my notebook seems to have correct performances.

I can't understand and I will investigate but I have no clue for now.
Page Index Toggle Pages: 1