Start Pre-allocating And Stop Worrying
gamesfromwithin.com
gamesfromwithin.com
Or, use a platform that handles dynamic allocation for you, or that lets you perform "object" based memory management instead of size-based memory management.
A similar principle applies to locking: do as little as possible. If you can use a development platform that lets you solve your parallel/concurrent problem naturally without locking (like folks have applied functional programming to do so successfully), do it!