3 ms·
> What I find with generated C is that it often is prone to blowing the stack or missing cache far more than hand-written C would. There's often something funky
by elcritch 3y ago
> What I find with generated C is that it often is prone to blowing the stack or missing cache far more than hand-written C would. There's often something funky happening (Cheney-on-the-MTA) or it's a soup of function pointers and object references scattered haphazardly across memory.
Definitely a possibility. Nim does pretty well since it has concepts of stack values in addition to ref's unlike perhaps Chicken Scheme or others. Add in that the Nim compiler can do some large scale optimizations that are hard to do in had written C it can perform as well (or better!) than C with some work. Though it's easy to loose performance too if you're sloppy.