If i replace a single-core processor with a dual-core processor, Will it increase the throughput by two times ? If No, why throughput does not get doubled ?


It definitely won't increase by a factor of two; that would be a perfectly efficient increase in throughput. That's not possible since there's always some overhead. How much benefit you get will depend on a few factors:

  • It may not increase at all if the OS or programs you're running on it aren't equipped to schedule processes on different cores.

  • It might only increase by a little if the tasks you're doing aren't very parallelizable (e.g. they depend heavily on I/O or other slow non-CPU operations).

  • It might increase by a good deal if the tasks are "embarrassingly parallel", e.g., long runs of identical floating-point computations or prime-number factorization.

  • It might make things worse if there's too much context-switching because of dependencies between the processes, or if you need to sync things across the processes.


See http://en.wikipedia.org/wiki/Amdahl%27s_law for a good description about why it won't double your throughput, and how to analyze what the improvement actually will be.

  • Hey James, Very Good Link ! – Karthik Balaguru Jun 17 '10 at 19:26
  • @James +1 For learning something new. I've heard the 'law of diminishing returns' used to describe this issue but 'Amdahl's law' is new to me. Thanks for this. – Evan Plaice Jun 18 '10 at 6:52

Your throughput will only be better, if your code is written to take advantage of two processors. Generally, you will need to make sure that your code uses 2 or more threads of execution to perform the job.

Only in some cases you will see performance actually doubled, as there is some book keeping needed in order to have multiple threads running.


Only for things that are CPU bound. Things that are memory bandwidth or I/O bound will probably not improve at all.


It depends on what kind of code you're running. If you're compute-bound and your code uses threads then you may see a 2x throughput improvement (at the same clock speed). If you are memory I/O bound or single-threaded then you may see no improvement at all (or even a deterioration in performance).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.