How to minimize memory consumption

Started by
10 comments, last by Spoonbender 18 years, 8 months ago
Quote:but that isn't the point.

I invite you to re-read my statement and what it was in response to.

And you start caring about EXE size real fast if 1) you are paying the bandwidth bill 2) some poor 56Kers have to download it. Also, large and poorly arranged (or compressed) executables require longer to load and more memory at runtime.


Great tips, S1CA! I would add to that using custom allocators, especially if you hit STL heavily. It is easy to end up with hundreds of thousands of allocs (!), which are slow, fragment the heap and cost quite a bit of overhead.
E8 17 00 42 CE DC D2 DC E4 EA C4 40 CA DA C2 D8 CC 40 CA D0 E8 40E0 CA CA 96 5B B0 16 50 D7 D4 02 B2 02 86 E2 CD 21 58 48 79 F2 C3
Advertisement
Keep in mind that there's a reason why structs are usually padded. It's much faster to access if it's aligned on 32bit boundaries. Are you willing to trade speed for memory?

This topic is closed to new replies.

Advertisement