I was recently at the Conference Formerly Known As XFest, and one of the sessions I saw had a panel of various heavyweight technical directors weighing in on various things. Some of the things they all seemed to more-or-less agree on: memory allocation bad, STL bad.
Now, I'm kind of out of the loop with our new multithreaded universe, since I haven't had access to any dev kits for the past several months (but I did just order a multi-core, multi-processor machine recently - it should arrive any day now - so I should be able to catch up soon) but these guys seemed to be opposed to memory allocation and STL on consoles in general - a bias that they've carried with them since PS1 days, it seemed like.
I'd just like to weigh in with my own two cents. I thought I detected a certain amount of coder machismo in their rants, some Not-Invented-Here syndrome.
Okay, so it was a Microsoft show, and the Microsoft allocator sucks -- in fact, there was a whole talk basically on working around the Microsoft allocator -- so I can understand why everyone was going "look out for fragmentation, etcetera!"
I think it was Tony Cox who was the one voice of dissent -- he pointed out that any time you're creating a game entity and deciding where to put it in memory, you're doing allocation, whether it's done by a heap manager or your own custom fixed-pool thing.
So here's my take. And it's "agile" - use new, delete, malloc, free. Once you find out they're fragmenting, or not thread-safe, deal with it. It's quite easy to fix allocation later once you find out it's not working out for you. My favorite allocator is Doug Lea's malloc - first introduced to me by Wade Brainerd when we found out that the built in allocation on the Dreamcast wasn't doing it for us. Turned out dlmalloc didn't work that well on the DC either, but it was easily configurable to do what we wanted. (And I did run across a bug in dlmalloc a few years later, but Doug Lea was very responsive and fixed it in the latest build. How crusty am I? "I found a bug in Doug Lea's malloc!" Almost as good as finding a bug in Donald Knuth code.) dlmalloc is the allocator that the PS2 SDK used by default - how happy it made me.
Seems like everyone stresses about fragmentation. Fragmentation is actually a *solved problem* - http://portal.acm.org/citation.cfm?id=286864 - but the default Microsoft allocator doesn't use the low-fragmentation algorithm. Doug Lea's does. So as long as you're not doing weird allocations - like allocating and reallocating a block that's an eighth of your entire heap - you're good.
I don't actually know if dlmalloc is thread safe. It probably isn't.
And, long story short, there have been many console games that shipped on time, sold millions of units, got high scores on game rankings, and used new and delete and malloc and free.
On the other hand, I do kind of like fixed pools of entities, only because then I can use indices into the array instead of pointers, and fwrite and fread the entire block to the hard-drive as a savegame without rebasing anything. That's how we used to do savegame back in the day. Doing everything with pointers was considered a premature optimization.
Eh, I'll leave my pro-STL thoughts for another day.