module

Rubellite::Spinel

Integration module for Matz's Spinel ahead-of-time Ruby compiler. Compiles Ruby code into native C, built into a shared library, and called directly via pure C ABI function pointers with zero VM overhead.

Class methods

available?

Checks if the Spinel compiler binary is available

Source
compile_fn(ruby_code : String, name : String, args : Tuple, returns : Class)

Compiles a Ruby function with Spinel (or native C generator) into a loadable shared library

Source
generate_c_wrapper(ruby_code : String, func_name : String, c_arg_types : Array(String), c_ret_type : String) : String

Emits an optimized C wrapper for the given Ruby routine when Spinel compiler is invoked or simulated for AOT fast-path.

Source

Nested types