from Hacker News

Demystifying Ruby: It's all about threads (2024)

by kadrek on 5/15/25, 1:56 PM with 6 comments

  • by josefrichter on 5/15/25, 10:23 PM

    I remember Jose Valim’s work on this in Ruby ~15 years ago. And then he went on to create Elixir and we never looked back.
  • by jemmyw on 5/15/25, 10:26 PM

    > This makes Ruby threads lightweight (also known as “Green Threads”)

    It's a shame they got this wrong and didn't discuss threads much. Ruby threads, since 1.9, are really threads managed by the OS and are not green threads. The parallelism is limited by the goal interpreter lock, but calling out to non Ruby code may be parallel, otherwise all those libraries the author mentions wouldn't bother. That "may" is an annoying point of order though.