[Speex-dev] reducing the stack size

Alain alainm at pobox.com
Tue Feb 15 12:50:01 PST 2005



tunkeat escreveu:
> hi all,
> 
> the stacksize required for encoder and decoder
> are 32Kbytes and 16 Kbyes respectively.  i changed
> it to 20Kbytess and 8Kbytes and it seems to work.
> but need to trim further. can someone point me in
> the right direction to further reducing the stack size?
> thanks!

I once measured *exactly* how much stack I needed in a vary simple 
maner: Change the stack to a known clean memory area filled with all 
zeros, then see what is left. Of course this was in DOS 16bit, but I 
believe it could be done in many OSes. Then you jusr have to let the 
program run for a secific configuration an shoe stack usage at exit.

I just hope this helps...
Alain


More information about the Speex-dev mailing list