This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] Simplifying TARGET_EXPR
- From: Michael Matz <matz at suse dot de>
- To: Mark Mitchell <mark at codesourcery dot com>,Gabriel Dos Reis <gdr at codesourcery dot com>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Mon, 22 Jul 2002 11:24:39 +0200 (CEST)
- Subject: Re: [tree-ssa] Simplifying TARGET_EXPR
Hi,
On Sun, 21 Jul 2002, Mark Mitchell wrote:
> > Do you think we should always elide copy-constructors by default,
> > unless explicitly told the contrary?
>
> Yes.
>
> Maybe I'm developing an unhealthy paranoia.
And your coworkers too it seems ;-)
First, I think you meant debugging in general, not specifically with gdb,
didn't you? Because with -O2 programs are not debuggable easily with gdb,
even right now, so gdb-debugging should not be the reason to not elide
copy ctors (or more generally debugging with programs interpreting the
debug info). Then it can only be a form of printf debugging, or asserts.
But e.g. strict aliasing makes such debugging also harder in a similar
way, because valid, but possibly surprising, transformations are made. We
do them anyway, so that also can't be the reason to not elide copy ctors
by default.
So not eliding them should be done only when a switch is given. Maybe
-fno-surprising (which also would switch off other optimizations), or
-fdebug.
Ciao,
Michael.