[Ilugc] How to improve the throughput of c/c++ code

  • From: siddhesh.poyarekar@xxxxxxxxx (Siddhesh Poyarekar)
  • Date: Thu Sep 30 09:33:02 2010

On Thu, Sep 30, 2010 at 9:10 AM, Girish Venkatachalam
<girishvenkatachalam@xxxxxxxxx> wrote:

It is not a canned answer.

First thing is don't use C++. People think C++ is an improvement on C.

I believe in the above myself, but for the most part, it really does
not make that much of a difference. The biggest performance killer in
most cases is I/O. Do I/O efficiently and half the battle is won.

Second thing is never use threading.

http://www.softpanorama.org/People/Ousterhout/Threads/tsld001.htm

I know you people will not believe me till some reference is given. ;)


Nonsense. Read the slides again. I can't see how one can conclude that
threads are performance blockers and should always be avoided based on
those slides. Those slides try to show how event driven programming is
an easier alternative in a lot of cases. The slides are from 1997 and
they quote desktop environments as being single threaded. They haven't
been single threaded for quite some time now. Threads are fantastic if
you know how to use them.

-- 
Siddhesh Poyarekar
http://siddhesh.in

Other related posts: