Messages in this thread | | | Date | Wed, 2 Jun 2004 09:25:50 -0700 (PDT) | From | Linus Torvalds <> | Subject | Re: [RFC PATCH] explicitly mark recursion count |
| |
On Wed, 2 Jun 2004, Jörn Engel wrote: > > Works for me for trivial recursions (just one function involved. With > a little more pain, it should work for basically everything. Only > exception are multiple recursions around the same function. So unless > you like to keep those suckers, I'm fine with it.
Well, multiple recursion around the same function seems to be solvable two different ways: - "don't do that then". It really seems broken, but maybe there are really really good reasons _why_ it's not broken and why it happens. - make sure that the separate loops are broken in some _other_ place than in the function they share.
A combination of the two may work well.
I say "may", because maybe I'm wrong, and the condition is common and hard to avoid limiting in the shared function. I don't have your data (and I'm lazy, so quite frankly I'd much rather you do the analysis anyway ;).
That said, I just don't see any sane alternatives to my "break in one place" thing. I believe that anything more complex that tries to explain the whole loop is just going to be a nightmare to maintain, and fragile as hell except for totally static legacy code that nobody touches any more.
Linus - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |