Project

General

Profile

Actions

Bug #2505

closed

Threads behave inconsistently across platforms.

Added by docwhat (Christian Höltje) over 15 years ago. Updated about 14 years ago.

Status:
Rejected
Target version:
-
ruby -v:
1.9.1-p376
Backport:
[ruby-core:27244]

Description

=begin
In Ruby 1.9, Thread is now using native threads. The problem with this is that threading models don't work the same across different platforms.

Some examples:
priority doesn't do the same thing on Solaris than Linux.
loop{} will lock the process up in Solaris, but not Linux.

There are plenty of other examples.

In addition, the fact that native threads use the same class name is also confusing. It means that code that would work on fully GIL encumbered green threads would work fine but may break in mysterious ways using native threads.

Finally, there is the fact that any code that could possibly be called from a native thread now has to be thread safe, making writing C extensions difficult.
=end

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0