This is the mail archive of the
mailing list for the GCC project.
Re: [tree-ssa][rfc] plans for nested functions
- From: Linus Torvalds <torvalds at osdl dot org>
- To: Richard Henderson <rth at redhat dot com>, gcc at gcc dot gnu dot org
- Date: Fri, 26 Sep 2003 16:29:56 -0700
- Subject: Re: [tree-ssa][rfc] plans for nested functions
- Organization: OSDL
- References: <20030926213651.GC21887@redhat.com>
- Reply-to: torvalds at osdl dot org
Richard Henderson wrote:
> This is stuff that was running around my head this morning.
> I mostly wanted to write this down so that I don't forget...
> The problem I'm trying to solve is that, at present, we have
> ordering issues wrt compilation of nested functions.
> (1) We depend heavily on rtl-level state in order to compile
> nested functions.
Why do you want to continue to support nested functions in the first
place? They are an abomination, a gcc-specific extension, and nobody
sane uses them (yeah, yeah, libobj, but I said _sane_).
Some ideas are just bad. Nested functions was one such idea. The
implementation used to do bad things (icache flushes at run-time,
for christ sake!).
Maybe you could support a specific subcase of nested functions where
they are always inlined, and basically do some slightly less nasty
tree-based inliner thing rather than any real nesting. And document
the horror as being a bad idea and only supported for legacy gcc
Are there really any users that do not deserve to either be fixed
or just shot in the head?