threading and multicores, pros and cons

Paul Rubin http
Wed Feb 14 01:44:02 EST 2007


Maric Michaud <maric at aristote.info> writes:

> Le mercredi 14 février 2007 05:49, Paul Rubin a écrit :
> > Basically Python applications are usually not too CPU-intensive; there
> > are some ways you can get parallelism with reasonable extra effort;
> Basically, while not CPU intensive, application server needs to get
> benefit of all resources of the hardware.

But this is impossible--if the application is not CPU intensive, by
definition it leaves a lot of the available CPU cycles unused.

> When a customer comes with his new beautiful dual-core server and
> get a basic plone install up and running, he will immediately
> compare it to J2EE and wonder why he should pay a consultant to make
> it work properly.  At this time, it 's not easy to explain him that
> python is not flawed compared to Java, and that he will not regret
> his choice in the future.  First impression may be decisive.

That is true, parallelism is an area where Java is ahead of us.

> The historical explanation should be inefficient here, I'm
> afraid. What about the argument that said that multi threading is
> not so good for parallelism ?  Is it strong enough ?

It's not much good for parallelism in the typical application that
spends most of its time blocked waiting for I/O.  That is many
applications.  It might even even be most applications.  But there are
still such things as CPU-intensive applications which can benefit from
parallelism, and Python has a weak spot there.



More information about the Python-list mailing list