True Parallelism with Global Mutable State in Ruby

2025-03-25

This article explores achieving true parallelism with concurrent data structures in Ruby, overcoming the limitation of built-in Ruby primitives that don't support global mutable state for concurrency. The author demonstrates a method to achieve this, requiring familiarity with Ruby, Rust, and C, along with some additional tooling. Code examples are available on GitHub and require a recent Ruby version (master branch recommended for local compilation), Rust, and C compilers.

Development