Introduction to CRuby source code
summary
Build CRuby from source: checkout a stable tag, install OpenSSL, run ./configure, then make, make check (≈14,000 tests) and make install; set PATH and GEM_HOME. Use lldb / gdb / Xcode debuggers to break into C functions called from Ruby. Edit C files to define classes/methods (data_Make_Struct, rb_define_method, NUM2LONG, LONG2NUM), or add extensions. Measured speedups: Fib in C ≈30× faster, prime ≈17×, some C routines and grid creation hit 19–50×.
AI-written summary · about
chapters (7)
- 0:00Start
- 0:26Introduction to CRuby Source Code
- 2:20Build Ruby from Scratch
- 7:41Debugger
- 25:23Graphs
- 25:55Extract code into a gem
- 27:52Questions?
related talks
29mIntroduction to CRuby source code
26mReading Ruby - A Visual Walkthrough of the Source Code
08mHow to Begin Developing Ruby Core
35mPragmatic Testing of Ruby Core
30mGuide to getting started walking source codes of CRuby
39mC how to supercharge Ruby with Rubex
55mCrystal for Rubyists
32mExperiments in sharing Java VM technology with CRuby
