Hacker News new | ask | show | jobs
by dhruvdh 1203 days ago
There is no way it will take a whole second regardless. Even when compiled in debug mode, it takes about 100 ms.

Try it here, I had Bing AI write it out - https://play.rust-lang.org/?version=stable&mode=release&edit...

1 comments

OP isn't talking about the performance of Rust code to calculate fib(35), but rather the performance of a Rust implementation vs a Zig implementation of an interpreted language executing code to calculate fib(35). They are saying that the Rust VM they wrote is slower than the Zig VM they wrote.
And, in particular, an interpreted dynamically typed language.
From a book that was a real joy to read and take one’s first steps into the magical world of compilers —- thank you for writing it!
You're welcome! I'm glad you liked it.