Hacker News new | past | comments | ask | show | jobs | submit login

It isn’t even zero runtime cost abstraction though. Monomorphizing all generic functions increases code size. Increased code size causes more instruction cache pressure which may actually slow things down, depending on the application. I could imagine if you’ve got some very large functions that are called on a wide variety of objects then every call could blow out the Icache and kill the hit rate.



It's an abstraction over writing out the monomorphized version by hand. Zero-cost doesn't mean using the abstraction gets you the fastest possible implementation of whatever you're doing.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: