News for hackers. Stuff that matters.
Re:Writing a Simple Linux Kernel Module by flukus on Friday December 01, 2017 @01:36AM (#15822358)
Another issue I've seen with rust (benchmarks) that's rarely talked about is memory usage, which is pretty important in a kernel. Sometime it only uses a little more memory, but quite often it will use twice as much and occasionally an order of magnitude more.

To be fair these benchmarks are aiming for speed, but the c baseline typically produces faster code with less memory, so it may very well be a case of TANSTAAFL.

Re:Writing a Simple Linux Kernel Module by madez on Friday December 01, 2017 @01:41AM (#15822379)
I don't see how it necessarily must be TANSTAAFL. Maybe Rust is indeed suited for being zero-cost in memory and speed performance compared to C, but the toolchain isn't there yet.
Re:Writing a Simple Linux Kernel Module by steveklabnik on Friday December 01, 2017 @08:19AM (#15823596)
We use jemalloc by default, which does its own caching. A closer comparison would be to use the system allocator, or make the C code use jemalloc as well.