Re: [cc65] Own parameter call stack?

From: Ullrich von Bassewitz <>
Date: 2009-09-01 16:56:52
On Tue, Sep 01, 2009 at 04:46:20PM +0200, Christian Krüger wrote:
> The gain would be a little bigger since you could use an other addressing mode:

You're right, I didn't realize that in this special case the stack can be in a
known location. But the other arguments still hold true. If we could just
replace the current stack by a fixed 256 byte stack, that would be ok, but
we'll need to have both, so this is a lot of work. And if I have to choose, I
choose the generic case.

> But today I could also ran into a stack overflow without a warning?

If you enable stack checks, yes. But since the stack is larger, the chance
that this happens is much smaller. Actually the whole space between top of
memory and the program is used for the stack, so even if you do recursion and
use 5 or 10K of stack, you won't notice problems in most cases.



Ullrich von Bassewitz                        
To unsubscribe from the list send mail to with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Tue Sep 1 16:58:56 2009

This archive was generated by hypermail 2.1.8 : 2009-09-01 16:58:58 CEST