On 2005-11-10T12:52:07, Jan Beulich <[email protected]> wrote:
> >If there's a chance of a stack overflow the stack usage has to be
> >reduced until the chance goes down to 0.
> How does one reduce stack usage in the presence of recursion driven by
> user input (referring to expression evaluation)?
Recursion removal is a pretty standard technique and featured in almost
all introductionary computer science texts. A quick google query finds
http://portal.acm.org/citation.cfm?id=359344
All recursive algorithms can be expressed non-recursively, although it
might not always be as nice. Or you can put an upper limit on the
allowed complexity of queries.
Sincerely,
Lars Marowsky-Brée <[email protected]>
--
High Availability & Clustering
SUSE Labs, Research and Development
SUSE LINUX Products GmbH - A Novell Business -- Charles Darwin
"Ignorance more frequently begets confidence than does knowledge"
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]