From: Dan Kegel <dank@kegel.com>
To: Fery <engard.ferenc@innomed.hu>
Cc: "crossgcc@sources.redhat.com" <crossgcc@sources.redhat.com>,
GCC Mailing List <gcc@gcc.gnu.org>
Subject: Re: number of vector template instances and pointers
Date: Mon, 20 Sep 2004 15:40:00 -0000 [thread overview]
Message-ID: <414EEF30.7030800@kegel.com> (raw)
In-Reply-To: <414EAD5B.C7A34222@innomed.hu>
Fery wrote:
> When I create two vectors with different pointer types (e.g.
> vector<char*> and vector<int*>), gcc compiles in two instances of vector
> code. In SH architecture, it means cca. n * 10K of code, which is quite
> big in our project.
>
> The question is, can I somehow force the compiler to use the same code
> for the two template instances?
If the object code generated for the two is really identical,
then if you really wanted to, you could write a whole-program
optimizer pass that combined them.
This is a topic for the gcc or libstdc++ mailing lists, though,
where people actually know something about this, so I'm redirecting there.
- Dan
--
My technical stuff: http://kegel.com
My politics: see http://www.misleader.org for examples of why I'm for regime change
next parent reply other threads:[~2004-09-20 14:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <414EAD5B.C7A34222@innomed.hu>
2004-09-20 15:40 ` Dan Kegel [this message]
2004-09-20 17:48 ` Joe Buck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=414EEF30.7030800@kegel.com \
--to=dank@kegel.com \
--cc=crossgcc@sources.redhat.com \
--cc=engard.ferenc@innomed.hu \
--cc=gcc@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).