[CELT-dev] CELT grabbing 100KB of memory right off the top

Gregory Maxwell gmaxwell at gmail.com
Mon Apr 18 12:59:05 PDT 2011


On Mon, Apr 18, 2011 at 3:52 PM, Andrew Lentvorski <bsder at allcaps.org> wrote:
> Is there a particular reason why CELT grabs 100KB of stack immediately?
> Is that really required or can that be trimmed down some/a lot?

No, it's not a requirement. The actual memory usage should be much
lower than that.

This only happens in any case if libcelt is compiled in pseudostack
mode. If you instead compile for use with C99 var arrays (or alloca)
then it doesn't do that.

I also think that there are a number of places where the peak stack
usage is much more than strictly required, The MDCT comes to mind.



More information about the celt-dev mailing list