Speeding Up Class#new
Aaron Patterson
• Cracow, Poland
•
Talk
Date: February 28, 2025
Published: Mon, 17 Mar 2025 00:00:00 +0000
Announced: Tue, 26 Nov 2024 00:00:00 +0000
Many Ruby developers like to initialize new objects, so let's take a dive into Ruby object initialization! What makes initializing an object slow? Can we use Ruby to speed it up? In this talk, we will examine the internals of the `Class#new` method, explore the trade-offs between Ruby and C method calls, and experiment with a Ruby implementation of `Class#new`. Additionally, we will discuss strategies for speeding up Ruby method calls, such as inline caches, while also considering the drawbacks of moving from C to Ruby.
Ruby Community Conference Winter Edition 2025