2 ms·
Well, that would be a statically linked Rust version vs a dynamically linked C version. Either of those languages can produce binaries of either size. Staticall
by steveklabnik 11y ago
Well, that would be a statically linked Rust version vs a dynamically linked C version. Either of those languages can produce binaries of either size. Statically link a MUSL libc and it'll be bigger than 6kb, dynamically link the rust code and use the system allocator instead of jemalloc and it'll be smaller than 2MB. (Or rather, it should be, I haven't literally tried it. The smallest known Rust executable is 151 bytes.)
- acqq 11y agoThat's what I wanted to hear, could really the mentioned in Rust implemented coreutils be compiled and linked equivalently to C or not and can we see the resulting sizes? Not "if I don't use any library I can get the 151 byte binary" but exactly these coreutils that are presented. It gives a good idea if the replacements can actually be comparable replacements. The second part is then to compare the number of features implemented and the behavior.