Rust's implementation of fasta is the third fastest on the language shootout, and uses no unsafe code. Really impressive.
Related Posts
Over a sufficiently long time horizon, all code you write is legacy code.
TIL Tcl has a notion of 'safe interpreters', a mode where you can run untrusted code in a sandbox: https://www.tcl.tk/man/tcl8.4/TclCmd/safe.htm
Not many programming languages have this, but it's way safer to include in the implementation than try to build as a userland library.
It's really satisfying to use a profiler for the first time on a project. I always find a big performance win with only a small code change.
It's never the code that I expected to be slow, however!