Global lock

Hi there!

Does Ruby threading model uses a global lock as Python uses?

Thanks!

Hi,

In message “Re: Global lock”
on Sun, 15 Oct 2006 01:03:37 +0900,
“=?utf-8?Q?Eust=c3=a1quio_Rangel?=” [email protected] writes:

|Does Ruby threading model uses a global lock as Python uses?

No. It’s worse (in a sense). It uses its own green thread.

						matz.

Yukihiro M. wrote:

|Does Ruby threading model uses a global lock as Python uses?
No. It’s worse (in a sense). It uses its own green thread.

Thanks for your answer, Matz! Can you give me a tip where I can learn
more things about this matter? I mean, some URL for
documentation/article or where to look on the Ruby source code?

Thanks again!

Hi,

In message “Re: Global lock”
on Sun, 15 Oct 2006 02:04:02 +0900,
“=?utf-8?Q?Eust=c3=a1quio_Rangel?=” [email protected] writes:

|Thanks for your answer, Matz! Can you give me a tip where I can learn
|more things about this matter? I mean, some URL for
|documentation/article or where to look on the Ruby source code?

See Download Ruby for source download
instruction. For threading matters, eval.c has everything.
Note: beware. it’s a black magic inside.

						matz.

On 10/16/06, Yukihiro M. [email protected] wrote:

In message “Re: Global lock”
on Sun, 15 Oct 2006 02:04:02 +0900, “=?utf-8?Q?Eust=c3=a1quio_Rangel?=” [email protected] writes:

|Thanks for your answer, Matz! Can you give me a tip where I can learn
|more things about this matter? I mean, some URL for
|documentation/article or where to look on the Ruby source code?

See Download Ruby for source download
instruction. For threading matters, eval.c has everything.
Note: beware. it’s a black magic inside.

Jumping directly to eval.c can be very scary.
It is probably easier to follow order given in
http://eigenclass.org/hiki.rb?ruby+internals+guide

See Download Ruby for source download
instruction. For threading matters, eval.c has everything.
Note: beware. it’s a black magic inside.

Jumping directly to eval.c can be very scary.
It is probably easier to follow order given in
eigenclass.org

I download and compile the sources on every release, I made a Slackware
build file some months ago for it. :slight_smile:

I opened eval.c before, just needed to make sure I was on the right
place (I searched for “thread” on the source code and there I was) and
as you and Tomasz said, it’s scary and looks like black magic going
directly there, but I’ll take a look carefully.

Thanks again!