Are threads bad? - was: Future of Pypy?

Marko Rauhamaa marko at pacujo.net
Wed Feb 25 00:46:47 EST 2015


Marcos Almeida Azevedo <marcos.al.azevedo at gmail.com>:

> Synchronized methods in Java really makes programming life simpler.
> But I think it is standard practice to avoid this if there is a
> lighter alternative as synchronized methods are slow. Worse case I
> used double checked locking.

I have yet to see code whose performance suffers from too much locking.
However, I have seen plenty of code that suffers from anomalies caused
by incorrect locking.


Marko



More information about the Python-list mailing list