This post originated from an RSS feed registered with Java Buzz
by dion.
Original Post: Rewritting malloc for that extra bit of performance
Feed Title: techno.blog(Dion)
Feed URL: http://feeds.feedburner.com/dion
Feed Description: blogging about life the universe and everything tech
A long time ago, I was leaked the codebase of a popular id software game, both before optimization, and after.
When you ended up seeing was:
prototype: mainly C/C++, with some assembler
production: assembler all over. all over.
They also used a special malloc. I remember at the time thinking: "they freaking rewrote malloc?". In fact the special version came from a Finnish group of uber-hackers, and even that was customized for certain corner cases when it made sense.
This all came to light when I read tcmalloc success which discusses Domas Mituzas of MySQL using tcmalloc (an open source Google perftool) to debug some nasty memory leaks.