Re: post C++ template/inlining resolution

comeau@panix.com (Greg Comeau)
5 Jun 2003 23:08:46 -0400

          From comp.compilers

Related articles
post C++ template/inlining resolution simon_newsgroup@mookstar.co.uk (Simon) (2003-05-24)
Re: post C++ template/inlining resolution idbaxter@semdesigns.com (Ira Baxter) (2003-05-29)
Re: post C++ template/inlining resolution sbeasley@cs.uic.edu (2003-06-03)
Re: post C++ template/inlining resolution comeau@panix.com (2003-06-05)
Re: post C++ template/inlining resolution comeau@panix.com (2003-06-05)
| List of all articles for this month |

From: comeau@panix.com (Greg Comeau)
Newsgroups: comp.compilers,comp.lang.c++
Date: 5 Jun 2003 23:08:46 -0400
Organization: Comeau Computing; http://www.comeaucomputing.com
References: 03-05-174
Keywords: C++
Posted-Date: 05 Jun 2003 23:08:46 EDT

Simon <simon_newsgroup@mookstar.co.uk> wrote:
>I would like somehow to be able to define a set of C++ template types
>(including inline methods that are fairly simple), and pass it through
>something to get out an intermediate version (in C or some
>representation that is vaguely human readable) so I can see what it
>has resolved to and what the compiler has to play with. The main goal
>is to check nothing is getting in the way of it all folding out so
>there is no overhead.


What do you mean? Don't you have the template so that they will be
used?


>Looking at ASM has gone too far, as by that time
>the compiler has made tradeoffs etc. I want to see what it has to play
>with before it has made any decisions.
>
>Is there anything out there to do this, be it a primary function or
>some flag that dumps out an intermediate representation of some form.


Maybe just turn off inlining, and then don't define any functions.
And then you'll get link errors telling your which functions it was
trying to find.


If this doesn't help, then I don't understand what you're asking.
--
Greg Comeau/ 4.3.0.1: FULL CORE LANGUAGE, INCLUDING TC1
Comeau C/C++ ONLINE ==> http://www.comeaucomputing.com/tryitout
World Class Compilers: Breathtaking C++, Amazing C99, Fabulous C90.
Comeau C/C++ with Dinkumware's Libraries... Have you tried it?


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.