1283
Is this a Nut? (media.gehirneimer.de)
you are viewing a single comment's thread
view the rest of the comments
[-] sxan@midwest.social 1 points 7 months ago

Everything is slower than C (I haven't seen a benchmark yet where a language bests C; even hand-crafted ASM ceded the high ground decades ago when compilers got better than human assembly programmers), but then, C compiler technology has had literally 40+ years to mature.

Go and Java (once warm) do pretty well, but absolutely give up execution speed for coding simplicity and (in Go's case, anyway) speed. Nim is young; I'm curious to see how it matures. They're having a bit of a performance crisis at the moment, but assuming they get past that it seems like a fair middle ground between Go's simplicity and Rust's bare-metal performance. Then again, manual memory management was absolutely my least favorite thing about C and is what eventually drove me away; worst. Boilerplate. Ever. Even worse than Go's error handling (which they almost fixed and looks like will be addressed within the next free releases). Anyhoo, going back to that shit is going to be a hard pill to swallow.

Rust is still having its honeymoon, and is the hip language of the decade now. We'll see!

[-] nick@campfyre.nickwebster.dev 1 points 7 months ago* (last edited 7 months ago)

Rust is roughly similar to C in most of these benchmarks and beats it in a few: https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/rust.html

Arguably when LLVM gets a bit better, Rust can be even faster than C because rust can be optimised in more places safely than C code can. The issue is that LLVM wasn't written with that in mind, so some performance is left on the table.

this post was submitted on 14 Mar 2024
1283 points (98.5% liked)

Programmer Humor

19551 readers
988 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS