On Fri, 16 Oct 2009 08:00:12 -0400, Olin Lathrop wrote: >Terry Harris wrote: >> But if you allocate them all statically and they don't fit in your >> available memory you are screwed. > >I'm missing the logic here. How is discovering in the lab at build time >that you are out of memory worse than not discovering it and having the >system fail while in use? It isn't. The problem is that if say we assume heap allocation is twice as efficient as static worst case everything allocation then half the time your static allocation says there is a problem it wouldn't actually be a problem if you used heap instead. The certainty offered by static allocation isn't free it may cost you more memory or performance (from having to reduce worst cases to make it fit). Certainty is probably impossible with a heap but certain enough may not be difficult, especially when you can afford a large contingency and still be more efficient than static allocation. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist