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.
IndexDiscussionGeneral Discussion,  Status › MacBook Performance!
Page Index Toggle Pages: 1
MacBook Performance! (Read 4035 times)
MacBook Performance!
May 31st, 2006, 7:09am
 
So ever since those beautiful black macbooks debuted (they REALLY do have a beautiful finish) I've been wondering if it would be worth upgrading. And also if it would be an upgrade at all.

Ive scoured the internet looking for tests and bargraphs and charts squaring off the macbook against it's pro bretheren and other random machines. They give me blips and numbers and percentages and none of them meant a whole lot to me. I needed some number I could relate to.

Also, the most intensive program I use (or at least the one I'm most worried about) is Processing. I like the GL library and making 3d things that spin and loft about. I know the major difference between the macbook and the macbook pro is it's video capabilities, and therefore it's GL capabilities.

So I decided to knock both birds with one stone. I wrote a little program that cranks out both float-intensive and GL-intensive work.

The algorithm runs a loop a certain number of times, each loop runs 3 3D perlin noise functions, changes the fill color, and draws a polygon. This starts the loop at 50 times per frame. Every time you click, the loop number doubles. The frames per second is displayed as this happens.

So I figure, the higher the frames per second, the better the performance, right? Note I'm running this straight from Processing and not in a browser as applet seems to murder performance.

First I tested this on my laptop. I have a 3 year old 10lb beast. It's a 2.6Ghz Pentium 4 HT with 1GB of ram and a ATI Mobility Radeon 9600 with 128MB shared from ram. I got:
50 polygons => 140fps
100 => 110
200 => 64
400 => 50
800 => 28
1600 => 16
3200 => 8
6400 => 4
And at this point I stopped.

So with these numbers scribbled in my pocket notebook and this program on a thumb drive I drove off to the nearest apple store to try out those new macbook machines!

First I decided to try the Black Macbook (So pretty!). Also as a side note, I really do prefer the new keyboard design, check it out it's very slick. "About this Mac" revealed a 2Ghz Duo and 512MB of ram and the Intel graphics with 64Mb shared. I ran the program and noted the numbers:
50 polygons => 50 fps
100 => 30
200 => 27
400 => 17
800 => 12
1600 => 7
3200 => 3
At this point about 3 minutes has gone by and I decided to pick up the macbook with my fingertips to test for heat (and weight I guess). It's nice and light compared to my beast and it wasn't too hot. I could have this on my lap while churning through CPU without too much discomfort.

Next I tested the 17" Macbook Pro. This is pretty as well, but I prefer that black finish, and the keyboard isn't as nice either. But regardless it must be tested. About this mac reveals: 2.16Ghz Duo with 1Gig of ram and the ATI video with 256M ram. Ran the program, here are the numbers:
50 polygons => 320fps
100 => 270
200 => 225
400 => 183
800 => 145
1600 => 110
3200 => 55
6400 => 29
12800 => 14
25600 => 7
At this point I tried the same lift with the fingertips test. Let's just say that I did this test 2 hours ago and my fingers are still hot and numb. I got seriously scaulded. Extremely hot.

So the verdict is that I'm not impressed enough to buy a new mac yet. The beautiful black Macbook is only 1/3 the speed of my current 3 year old laptop. It's cute and small and portable and not too hot, but it lacks the power needed to do this kind of work. Boo :(. The Macbook Pro however is a power freak. Easily tripling the speed of my current laptop. If you want to do some hot GL action, this thing is the way to go. However prepare to be seriously roasted. I always thought the powerbook design was a little outdated looking and it missed out on the keyboard innovation with the macbook. The macbook pro is easily 10 times as fast as the black macbook when it comes to processing GL work.

The great thing about this test was that the numbers actually meant something. Since I could run the same test on my machine I got a feel for a relative speed increase or decrease.

Run this on your computer and post your computer/vidcard's stats and the numbers you get! I'm really interested to see what kind of range of performance is out there.


Download this bit of code (and font file) here: http://public.megamu.com/twirliegig.zip
Re: MacBook Performance!
Reply #1 - May 31st, 2006, 7:10am
 
Here is the code for those who just want a glance:

Quote:


import processing.opengl.*;

int polygons = 50;
int counter=0;




float hue = 0;
float x,y,z,vx,vy,vz;
float frames = 0;
float thisTime,lastTime;


void setup(){
 size(1280,800,OPENGL);
//  framerate(100);
 colorMode(HSB,1);
 noStroke();
 x=0;
 y=0;
 z=0;
 thisTime = 0;
 lastTime = 0;
 textFont(loadFont("V.vlw"),60);
 textAlign(CENTER);
}

void draw(){
 background(0);
 
 if(counter++%40==0){
   lastTime = thisTime;
   thisTime = millis();
   frames = roundTo(40*1000/(thisTime-lastTime),3);
   fill(1);
   println(frames + " ["+polygons+"]");
 }
 
 fill(1);
 textSize(80);
 text( frames ,width/2,height/2);
 textSize(40);
 text( polygons+" polygons",width/2,height/2+80);
 
 translate(250,0,0);
 beginShape(TRIANGLE_STRIP);
 for(int i=0;i<polygons;i++){
   hue += .001;
   while(hue>.3)
     hue=0;
   fill(hue,1,1,.1);
   x = noise(x,y,z) * 800;
   y = noise(y,z,x) * 800;
   z = noise(z,x,y) * 800;
   vertex(x,y,z);
 }
 endShape();

 
 


}

void mousePressed(){
 polygons = polygons*2;
}


float roundTo(float num, int places){
 float multi = pow(10,places);
 num = round(num*multi);
 return num/multi;
}


Re: MacBook Performance!
Reply #2 - May 31st, 2006, 12:57pm
 
the problem with the macbook is that apple is using the same integrated intel graphics as in the mac mini, so its opengl performance suffers. very disappointing, this was one of the best things about my old ibook, that it had a reasonable gfx card that gave it a much longer useful lifetime for me, not to mention costing only ~$1000 instead of the $3k or whatever for the powerbook/mbp.
Re: MacBook Performance!
Reply #3 - Jun 1st, 2006, 12:02am
 
Hey, so I was curious to see what the difference would be between the OS X and Windows performance, so I tried your sketch on both OS's on my MBP. On OS X i got pretty close to exactly the same results as you did for the 17" (mine is a 15"), but here's what I got when I ran it on windows:

50 polygons => 40fps
100 => 40
200 => 40
400 => 40
800 => 40
1600 => 28
3200 => 25
6400 => 18
12800 => 11
25600 => 6

Weird! The FPS is getting capped at 40, and even then it's not even half of what I got in OS X.. I hadn't noticed it til now because usually my sketches are set to run at 40fps or less. I guess the windows graphics drivers are just not up to spec for the MacBook pro yet..
Re: MacBook Performance!
Reply #4 - Jun 1st, 2006, 2:34am
 
Scloopy:
That's really interesting! I wanted to test on windows on mac but didn't have a chance since I really just waltzed into the macstore and ran it off a thumbdrive. 40fps is pretty speedy and fast enough to be considered smooth, but it is very strange that it gets capped. It's still faster than my current laptop!

I'd be interested to see how much different this runs on windows (or linux!) under Parallels or similar virtualization software since it's SO much easier to whip back and forth between OS's with it!
Re: MacBook Performance!
Reply #5 - Jun 1st, 2006, 3:20am
 
I just got a new Dell computer at work and installed the latest drivers and ran the test. Also interesting results.

Pentium 4 3.2 Ghz
2 GB Ram
NVidia Quadro FX 500

50 => 38
100 => 38
200 => 38
400 => 24
800 => 17
1600 => 11
3200 => 6
6400 => 3

I'm a little disappointed as I'll be doing some serious graphic work on here and I thought for the parts this test would prove much higher numbers. Still it approaches twice the speed of the macbook.
Re: MacBook Performance!
Reply #6 - Jun 1st, 2006, 11:11am
 
I think it doesn't actually get capped at 40, but jsut that framerate seems to have a limit to what it can report under windows.

If you divide frameCount by (millis()/1000.0) I find I get a true framerate (double so if you store the return of millis() from the en dof your setup() routine, and subtract that from millis() whilst calculating)
Re: MacBook Performance!
Reply #7 - Jul 24th, 2006, 9:12pm
 
Powerbook G4/667mhz

50->75
100->55
200->37
400->22
800->12
1600->6
3200->3


I'm impressed that my 5 year old laptop beats out the brand new macbooks...
Re: MacBook Performance!
Reply #8 - Sep 27th, 2006, 2:15am
 
I have a (black) MacBook with 2GB RAM.  Just going to give the numbers for the fewest and highest polygons:

50: 82-86
3200: 4.5-4.8
Re: MacBook Performance!
Reply #9 - Feb 26th, 2007, 5:01am
 
I just bump this topic because when i run this test i get a damn higher framerate.

without frameRate();

Quote:
62.598 [50]
62.696 [100]
62.5     [400]
62.598 [400]
62.305 [800]
62.402 [1600]
60.606 [3200]
53.121 [6400]
41.494 [12800]
17.021 [25600]
7.883   [51200]

with frameRate(400);
Quote:
333.333 [50]
303.03   [100]
251.572 [200]
206.186 [400]
159.363 [800]
120.12   [1600]
86.768   [3200]
43.243   [6400]
21.425   [12800]
11.252   [25600]
9.713     [51200]

MacBookPro 2.33Ghz 2GB RAM 1600XT 256MB

OS X 10.4.8 / P5 124 / Java 1.5
Re: MacBook Performance!
Reply #10 - Feb 26th, 2007, 8:23am
 
with frameRate(400):
My computer is macbook 1.83 intel Core 1 duo, 1gb ram.
n polys/ n frames
50----90
100---68
200---47
400---30
800---17
1600--10
3200--5
6400--4

I think mine has 40% faster than the black macbook is because I got 1gb instead of 512 mb ram.
performance
Reply #11 - Feb 26th, 2007, 11:53am
 
hello guys

Thank you for posting this!! I am recently considering getting a black macbook myself. I need it mostly for portability, I don't mind the performance sacrifice so long as I can carry it around easily and not have to worry about it breaking all the time.

Here are my stats on my toshiba tablet PC
2ghz single cpu
2gb ram
128mb vram NVidia Geforce GO

And the test results:
58.14 [50]
58.224 [100]
38.797 [200]
29.412 [400]
24.615 [800]
16.515 [1600]
10.038 [3200]
7.091 [6400]

It's capped at 60 even if I do framerate(400); for some reason.

Page Index Toggle Pages: 1