public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "zsojka at seznam dot cz" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/46188] -fipa-cp removes destructor call
Date: Wed, 27 Oct 2010 10:31:00 -0000	[thread overview]
Message-ID: <20101027103100.s8FNzDbv8tXApBSh65gi8UztbgLaPvMFyi30ejV-k48@z> (raw)
In-Reply-To: <bug-46188-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46188

--- Comment #5 from Zdenek Sojka <zsojka at seznam dot cz> 2010-10-27 10:30:35 UTC ---
Created attachment 22172
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22172
the second part of testcase

I used this file to complete your testcase. It defines remaining functions and
prints some debug output. (x86_86-pc-linux-gnu target)

gcc-4.5.2 (r165781)
$ g++ -O2 playground4.cxx playground_main.cxx && ./a.out 
pre-f()
Array<B>::do_something()
h(0x602030)
h((nil))
post-f()
h((nil))
h(0x602010)
h((nil))

$ g++ -O2 -fno-ipa-cp playground4.cxx playground_main.cxx && ./a.out 
pre-f()
Array<B>::do_something()
h((nil))
h(0x602030)
h((nil))
post-f()
h((nil))
h(0x602010)
h((nil))

gcc 4.6.0 (r165985)
$ g++ -O2 playground4.cxx playground_main.cxx && ./a.out 
pre-f()
Array<B>::do_something()
h((nil))
h(0x602030)
h((nil))
post-f()
h((nil))
h(0x602010)
h((nil))

For 4.5 -fipa-cp the output is different. I don't see anything obviously wrong
with the testcase, and valgrind doesn't anyreport any errors. But I am
certainly not an expert.

Apart from this:
#pragma interface
#pragma interface "subdir/objects.h"
    Use this directive in header files that define object classes, to save
space in most of the object files that use those classes.

It's not a header file and #pragma implementation is nowhere... I suppose the
testcase was reduced from preprocessed files.


  parent reply	other threads:[~2010-10-27 10:31 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-26 17:05 [Bug c++/46188] New: " jens.maurer at gmx dot net
2010-10-26 19:08 ` [Bug c++/46188] " pinskia at gcc dot gnu.org
2010-10-26 21:09 ` jens.maurer at gmx dot net
2010-10-27  6:14 ` jens.maurer at gmx dot net
2010-10-27  7:55 ` jens.maurer at gmx dot net
2010-10-27 10:31 ` zsojka at seznam dot cz [this message]
2010-10-27 13:17 ` jens.maurer at gmx dot net
2010-10-27 13:18 ` jens.maurer at gmx dot net
2010-10-27 15:44 ` zsojka at seznam dot cz
2010-11-10 19:11 ` [Bug c++/46188] [4.5 regression] " jason at gcc dot gnu.org
2010-11-10 23:01 ` rguenth at gcc dot gnu.org
2010-11-12 14:18 ` rguenth at gcc dot gnu.org
2010-12-16 13:06 ` [Bug tree-optimization/46188] " rguenth at gcc dot gnu.org
2011-02-05 15:19 ` mikpe at it dot uu.se
2011-04-18 14:52 ` rguenth at gcc dot gnu.org
2011-04-18 15:33 ` rguenth at gcc dot gnu.org
2011-04-19  9:00 ` rguenth at gcc dot gnu.org
2011-04-19  9:03 ` rguenth at gcc dot gnu.org

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=20101027103100.s8FNzDbv8tXApBSh65gi8UztbgLaPvMFyi30ejV-k48@z \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@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).