Are core2duos slower than single cores?
The "little things" are so insignificant compared to the cpu drain the loop causes, it's like throwing pebbles in the ocean, you can't create waves.Derek wrote:Shouldn't the single core be busy with all the little things that make the computer tick while the dual core has a friend to help out and should be belting along.
The other cpu/cores may make the system seem more responsive.
Almost as if you had put Delay(0) inside that loop but without the speed loss due to the constant context switching.
To put it another way, increase the run of the loop,
then start it and use a browser. (they usually run multiple threads)
Depending on how the OS does traffic control, if your lucky it will realize one core/cpu is very busy with that loop and put the browser and it's threads on the other cpu's. Hopefully allowing you to surf smoothly while the other cpu is working up a nice sweat.
Trying the same on a single cpu system and it will be like crawling through glue.
If you bring task manager up and watch the cpu usage when you run the first example both cores go from being barely used to about 50%, then one carries on up to about 66% and the other goes down to about 30-40%.
As you say, if I start a browser or other program then the lowest core picks up again and everything is quite smooth.
The only thing that puzzles me is why such a short program isn't cached in one cores cache and just run by that one core.
Still, this is why I don't design CPU's!!
As you say, if I start a browser or other program then the lowest core picks up again and everything is quite smooth.
The only thing that puzzles me is why such a short program isn't cached in one cores cache and just run by that one core.
Still, this is why I don't design CPU's!!

- Psychophanta
- Always Here
- Posts: 5153
- Joined: Wed Jun 11, 2003 9:33 pm
- Location: Anare
- Contact:
-
- Addict
- Posts: 1648
- Joined: Mon Sep 20, 2004 3:52 pm
- Contact:
- NoahPhense
- Addict
- Posts: 1999
- Joined: Thu Oct 16, 2003 8:30 pm
- Location: North Florida
For those MAC OSX users, here are the results using a Mac Book Pro 1.83 dual core running Parallels desktop build 1970 (latest stable) and windows XP Home
2403 without debugger
7241 with debugger
Not as bad as I thought really.
Code: Select all
OpenConsole()
start = ElapsedMilliseconds()
For n = 1 To 50000000
x.f = x.f+(1.0/Sqr(n))
Next
stop = ElapsedMilliseconds()
PrintN(Str(stop-start))
PrintN(StrF(x.f))
Input()
7241 with debugger
Not as bad as I thought really.
Leopard-parallels-XP-Vista
- Psychophanta
- Always Here
- Posts: 5153
- Joined: Wed Jun 11, 2003 9:33 pm
- Location: Anare
- Contact: