develooper Front page | perl.perl5.porters | Postings from March 2018

[perl #133021] Removed the word "discouraged" from threads'documentation

Thread Previous | Thread Next
From:
Sergey Aleynikov via RT
Date:
March 28, 2018 00:54
Subject:
[perl #133021] Removed the word "discouraged" from threads'documentation
Message ID:
rt-4.0.24-12689-1522198462-1218.133021-15-0@perl.org
On Mon, 26 Mar 2018 18:21:02 -0700, public@khwilliamson.com wrote:
> I agree with the above.  And I really don't like 'not recommended' as
> I
> think it is too strong.  Maybe just list the problems
> 
> Even a 30% slowdown will be fully acceptable if you can divide the
> work
> up into 8 or 16 parallel pieces.  The gain far outweighs the cost.

But if you use processes for parallelism and not threads, you don't get this slowdown at all and get the same multicore boost. And you don't have to guess which XS module will segfault next.  The only case when I find using threads reasonable is writing GUI, where you _have to_ be in the same address space.

---
via perlbug:  queue: perl5 status: open
https://rt.perl.org/Ticket/Display.html?id=133021

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About