Is Rust faster than C?

6 rbanffy 4 6/11/2025, 4:27:33 PM steveklabnik.com ↗

Comments (4)

tikotus · 1d ago
The outcome of the article seems to be: depends on how you look at it, but in general, it's hard to say.

So not many conclusions, but still interesting. I'm not really at all familiar with Rust so the title seemded backwards to me: how could it be? Did they mean it the other way around? But for example the struct reordering is a cool example of how Rust could be faster.

steveklabnik · 1d ago
> the title seemded backwards to me

I wrote the title this way because it's a question people ask.

> how could it be?

It can be because Rust is also a low-level language that's focused on performance. C does not have any inherent reason to be the fastest language.

> depends on how you look at it, but in general, it's hard to say.

Yep! I don't think there's a clear answer here. But that, in and of itself, is a useful result.

reify · 1d ago
I can only comment on two programs that I have used.

The old Crunch password generator and the more recent cracken password generator

I did a comparison side by side.

Craken is massively faster than crunch

https://lib.rs/crates/cracken

https://sourceforge.net/projects/crunch-wordlist/

anovikov · 1d ago
If it was faster than C, Firedancer won't exist.