Re: program runs almost twice as slow on 2 CPU machine when 1 CPU is u




"JC" <JC@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:908DDF92-9794-4768-900B-777ADC05B83C@xxxxxxxxxxxxxxxx
I have a 2 CPU WinXP pro. If my CPU intensitve program runs while there
is
already another CPU intensive program running, I find that this program
runs
almost twice as slow when there is no other program running.

In general, I found that when one CPU is being used, the program runs
20-30%
slower compared when one of the CPU is idle.

No, the program is not I/O intenstive.

What's wrong here? Any system property that I can set to change this?

Thanks a lot.

Why do you think that something is "wrong"? It sounds like things are
working the way they are supposed to: if yours is the only CPU intensive app
that's currently executing, then it gets all of both CPUs and runs fast,
whereas if it's not, then it must share CPU with other apps and it runs more
slowly.

Note: Your app might be designed to use only one CPU at a time, but other
apps might be designed to use as many CPUs are available (which is good).


.



Relevant Pages

  • [Summary] Diagnosis fun...
    ... 2% idle time sucks, and more than likely the system is CPU bound, and can ... app depends so heavily on the kernel, ... I replaced the default Solaris 8 TimeSharing dispatch table ...
    (SunManagers)
  • Re: Comments for reverse idea
    ... Is it possible to create a x86 CPU emulator, that "records" an app? ... recorded everything while executing it so that it could from ...
    (alt.lang.asm)
  • Re: Timing your loops
    ... loops it updates every iteration causing cpu usage. ... And yes i do need multiple separate windows. ... However all this said if letting the app suck 100% isn't actually a bad ... all the cpu power left....mustn't be left for a rainy day after all. ...
    (microsoft.public.win32.programmer.directx.managed)
  • Re: Timing your loops
    ... Instead of taking a 'greedy' approach that uses up as much CPU time as possible unless you remember to stop it, have you considered an approach whereby you generally do nothing, but occasionally you'll render a frame? ... Providing your timer-handling code takes less than 30ms to execute, your app should go back to sleep between frames. ... After all they are running and while doing nothing are allocated all the cpu power left....mustn't be left for a rainy day after all. ...
    (microsoft.public.win32.programmer.directx.managed)
  • Re: [Announce] [patch] Modular Scheduler Core and Completely Fair Scheduler [CFS]
    ... Matt Mackall wrote: ... Probably not if you use common sense, and in the context of a replacement ... Is it common sense that a heavily-threaded app should be able ... to get hugely more CPU than a well-written app? ...
    (Linux-Kernel)