chicken-janitors
[Top][All Lists]
Advanced

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

Re: [Chicken-janitors] Re: [Chicken-bugs] #356: inline recursion


From: Elf
Subject: Re: [Chicken-janitors] Re: [Chicken-bugs] #356: inline recursion
Date: Mon, 3 Dec 2007 17:16:44 -0800 (PST)


i consider it an extremely serious bug.  i have run into it in at least 4
separate libs or programs ive written, and theres no real way of knowing that
its inline-looping infinitely instead of merely taking a long time.  the
general cases where this has happened: some requirement for high efficiency,
some relatively small number of small external-interface procedures,
some relatively large number of very small procedures called exclusively by each other or some relatively small number of very large procedures called exclusively by each other, either a dispatch-return or a subloop using
the same set of procedures, and a single entry point between inlined and
non-inlined procedures. it sounds a lot more complex than it is. the current raw-sockets implementation in the funk repository ran into this problem
in several versions.  etxtproc (formerly eformat, not yet working in the eggs
repo) ran into it with essentially state machine transformations.  the current
workaround that ive used to get around the problem is to encapsulate potential
problem procedures in letrecs.... this only solves the self-loop case, however.

HOWEVER! this is a comparatively minor optimisation compare to some of what
we should be paying attention to, so simply putting a compiler warning and changing the one inline to non-inline would be more than sufficient in the
short term.  gc and number handling improvements would be orders of magnitude
more useful :)

-elf


On Mon, 3 Dec 2007, felix winkelmann wrote:

On Nov 30, 2007 9:55 PM, Elf <address@hidden> wrote:

glad to be of service.  i can try to work out if/how something like this could
be integrated into the extant code this weekend if youd like, as well as
checking to see if it actually works and optimising it properly. :)


Of course you can do that, but I can't promise that it will be integrated
that soon. Do you consider this a serious bug in chicken or just an
annoyance?


cheers,
felix





reply via email to

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