What porting? Isn't C++ the most portable language in existence? Oh, there is also Rust. But isn't it just uses an LLVM codegen, same as Swift or clang? So, there is Rust's stdlib.
Seems like these abstractions are not exactly zero-cost?
> But isn't it just uses an LLVM codegen, same as Swift or clang?
It's more complicated than that. I've been involved in a project (bootstrapping little-endian 32 bit PowerPC on linux) which needed a rust port. I didn't work on that, but from what I saw, it's at best a major nuisance, possibly a nightmare when something breaks. This may be a bad example since darwin/aarch64 is a more sane target, but still. ;-)
More importantly I guess, Firefox has some reeeeaally old platform specific cruft and some really rusty (hah!) ABI-glue stuff lying around. Stuff like the Netscape Portable Runtime. There's still code in Firefox from back when it ran on HP PA-RISC. There's even code for IBM Z mainframes in there. Really glossing over details, but there are some inner mechanisms that are very platform specific and need at least some custom code for each OS + CPU combo.
Seems like these abstractions are not exactly zero-cost?