Benchmarking programming languages and web frameworks

Ruby Computation Benchmark

About Ruby


Object-Oriented, Imperative





Null Safety


Memory Management

Garbage Collection

Ruby is a dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write. Developed by Yukihiro "Matz" Matsumoto in the mid-1990s, it was designed with an emphasis on programming happiness and expressive code. Ruby is commonly used for building web applications, notably through the Ruby on Rails framework, which is a full-stack web application framework that includes everything needed to create database-backed web applications according to the Model-View-Controller (MVC) pattern.


This benchmark tests how fast a programming language can perform mathematical computations without any I/O or memory allocation. We are using the Leibniz formula to approximate the value of PI.
Please note that the memory usage also includes the memory used by the HTTP server. Ideally, the most lightweight HTTP server should be used to measure the raw memory usage of the runtime.
Ruby (JIT v3.2)
48.24 s
10.5 MB
Ruby (JIT v3.1)
102.43 s
9.1 MB
Ruby (JIT v3.0)
110.41 s
9.2 MB
Ruby (JIT v2.7)
107.56 s
9.0 MB
Ruby v3.2
106.77 s
10.5 MB
Ruby v3.1
103.41 s
9.7 MB
Ruby v3.0
108.98 s
9.2 MB
Ruby v2.7
108.83 s
8.9 MB

© 2024 Tien Do Nam