Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> the C code is still going to be waaay faster than the Ruby code even with YJIT.

I can't find it but I remember seeing a talk where they showed examples of Ruby + YJIT hitting the same speed and in some cases a bit more than C. The downside was though that it required to some warmup time.



I find that hard to believe. I've heard claims JIT can beat C for years, but they usually involve highly artificial microbenchmarks (like Fibonacci) and even for a high performance JITed language like Java it ends up not beating C. There's no way YJIT will.

The YJIT website itself only claims it is around twice as fast as Ruby, which means it is still slower than a flat earth snail.

The benchmarks game has YJIT and it's somewhere between PHP and Python. Very slow.


I’ll see if I can find the presentation again on Youtube


Maybe "Ruby Outperforms C" was bait for "Outperforming a C extension" which is about the relative cost of calling C from Ruby?

https://railsatscale.com/2023-08-29-ruby-outperforms-c/




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: