This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] C++ space optimization: de-cloning con/de/structors,take II


The one unresolved point has to do with DECL_NUM_STMTS(); an objection
was raised, characterizing this usage as "bogus."
I should qualify that.

I thought you were using DECL_NUM_STMTS to figure out whether the
clone was doing anything interesting.  If you're just using it to
figure out how big it is, that's OK.  Using "non-trivial" in the
commment here is misleading; that has a different meaning for C++
wonks than for ordinary humans.

There are still some style nits; you don't have prototypes for
maybe_alias_body and maybe_thunk_body, and we're now using ANSI/ISO C
in the C++ front end so you should rework the function declarations.

In fact, maybe_alias_body should be removed; it's always a waste of
time at this point.

And, you definitely need to be using the "current_function_is_thunk"
stuff; if I read the code correctly you'll still be creating additional
copies which is not good.

--
Mark Mitchell                mark@codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]