7 ms·
Title reminded me of something completely unrelated: FFI overhead is not to be neglected sometimes. I've seen cases where replacing a python or js lib with an
by baobun 9mo ago
Title reminded me of something completely unrelated:
FFI overhead is not to be neglected sometimes. I've seen cases where replacing a python or js lib with an in isolation much faster native Rust or C lib with bindings had the end result being a decrease in real-world performance due to it being in a hot path or loop and the overhead being more significant than the savings were. There is no substitute for real-world benchmarks.
- ohr 9mo ago(Author here) yes! I also wrote about this (specifically in Python->Rust FFI) in another article: https://ohadravid.github.io/posts/2023-03-rusty-python/#v2---rewrite-even-more-in-rust https://ohadravid.github.io/posts/2023-03-rusty-python/#v2--...