Re: Ruby Thread

看板Ruby作者 (lala)時間17年前 (2006/11/04 10:41), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串4/7 (看更多)
※ 引述《b6s (http://b6s.blogspot.com)》之銘言: : ※ 引述《contagious (布穀飽吃不堡)》之銘言: : : 1. ruby 的這種模擬出來的 thread 叫 "gren thread"。系統提供的thread 叫 "native thread" : : 所以那篇說 : : "Ruby 2.0 would support neither continuations nor green threads. " : : 實在很奇怪,這樣是指沒有模擬的 thread 了嗎? : Green Thread 是 SunOS 稱呼 Light-Weight Process 的別名, : 同時可見於 FreeBSD 家族,在這類定義之下,可能不算是模擬。 : 但如果用後來 JVM 的定義又不一樣了: : http://java.sun.com/docs/hotspot/threads/threads.html : 如果 Ruby 有新的 interpreter,或是向 JRuby 的作法靠攏, : 那或許會跟 JVM 定義的類似,這是我對 : http://headius.blogspot.com/2006/10/another-year-another-interpreter.html : 這篇文章的理解。 : 至於 thread 和效能的關聯,通常在 database 部分比較會有感覺, : 而那是 database 和 OS 之間的問題。 : 因此我大致上也認為,這不是 Ruby 效能的瓶頸。 基本上,我將 Thread 當作一種語言的基礎建設的感覺來看啦 不是說 Thread 一定真的那麼重要 只是 Thread 作不好總覺得少了些什麼 至少這方面 Ruby 在 Thread 方面是處於弱勢的 能不能用其他地方補強起來 或是根本就有新的作法,這可能等 Matz 的回答 -- lighty RoR 是一個介紹 lighttpd , SQLite , Ruby and Rails 的 Blog http://lightyror.blogspot.com/ -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 61.230.107.64
文章代碼(AID): #15I_t4y8 (Ruby)
文章代碼(AID): #15I_t4y8 (Ruby)