[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-hackers] [PATCH] fix stack-overflow check

From: Christian Kellermann
Subject: Re: [Chicken-hackers] [PATCH] fix stack-overflow check
Date: Mon, 13 Aug 2012 13:04:39 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

* felix winkelmann <address@hidden> [120813 12:34]:
> The attached patch fixes the computation of stack depth beyond
> C_stack_limit. The old way of calculating the depth could overflow if
> the stack is located very high in memory. This was causing incorrect
> stack-overflow errors on some 64-bit systems (sparc64 and x86-64). The
> new method checks whether the stack-pointer is beyond the limit
> computed at startup, including a 64k "slack" area to allow (modestly)
> deep recursions in direct-call-optimized (simple, non-allocating, not
> externally visible) procedures, if the nursery is already mostly
> exhausted.
> This patch fixes ticket #895.
> I recommend to include this fix in the upcoming 4.8.0 release (this will
> require a new release candidate).

A minor nitpick from my side....

> +#define C_stack_overflow_check    C_stack_check1(C_stack_overflow())
> +
> +#define C_stack_check             C_stack_overflow_check
> +

According to "git grep C_stack_check" the only places where that
string is used is in the places where you replace it. Why not remove
it? Is it part of the API?

Kind regards,


Be right back -- Godot.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]