public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE
@ 2015-02-10 14:29 jakub at gcc dot gnu.org
  2015-02-10 14:35 ` [Bug middle-end/65003] " jakub at gcc dot gnu.org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-02-10 14:29 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

            Bug ID: 65003
           Summary: [5 Regression] -fsection-anchors ICE
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jakub at gcc dot gnu.org
                CC: hubicka at gcc dot gnu.org
            Target: armv7hl-linux-gnuaebi

struct A
{
  void operator= (A &);
  A ();
};
struct B
{
  A b;
};
struct C
{
  virtual bool foo (int &, bool) const;
};
struct D : virtual C
{
  bool foo (int &, bool) const;
  B e;
};
struct F : D
{
  F (int &, const int &, const A &);
  bool foo (int &, bool) const;
};
bool D::foo (int &, bool) const {}
F::F (int &, const int &, const A &) {}
bool F::foo (int &, bool) const {}

ICEs on armv7hl-linux-gnuaebi, with -O2 -fpic.  I believe the bug has been
introduced with r211045, but haven't verified it.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
@ 2015-02-10 14:35 ` jakub at gcc dot gnu.org
  2015-02-10 14:36 ` rguenth at gcc dot gnu.org
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-02-10 14:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2015-02-10
     Ever confirmed|0                           |1

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
      snode = symtab_node::get (decl);
      if (snode->alias)
        {
          rtx target = DECL_RTL (snode->ultimate_alias_target ()->decl);

          place_block_symbol (target);
          SYMBOL_REF_BLOCK_OFFSET (symbol) = SYMBOL_REF_BLOCK_OFFSET (target);
          return;
        }
is of course bogus, DECL_RTL is very unlikely a SYMBOL_REF, it should be a MEM
with SYMBOL_REF as operand.  The question is if we can assert that.  If that
wouldn't be the case, I guess the optimizers would need to prevent creation of
the alias.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
  2015-02-10 14:35 ` [Bug middle-end/65003] " jakub at gcc dot gnu.org
@ 2015-02-10 14:36 ` rguenth at gcc dot gnu.org
  2015-02-10 15:09 ` jakub at gcc dot gnu.org
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: rguenth at gcc dot gnu.org @ 2015-02-10 14:36 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P1
   Target Milestone|---                         |5.0


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
  2015-02-10 14:35 ` [Bug middle-end/65003] " jakub at gcc dot gnu.org
  2015-02-10 14:36 ` rguenth at gcc dot gnu.org
@ 2015-02-10 15:09 ` jakub at gcc dot gnu.org
  2015-02-11 15:10 ` jakub at gcc dot gnu.org
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-02-10 15:09 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 34713
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34713&action=edit
gcc5-pr65003.patch

Untested fix.  If the assert ever triggers, I guess we'll need to do something
smarter in the cgraph area.
Note that symbols that are aliases from the beginning aren't a problem here,
the only problem is if a symbol has RTL created too early (in this case because
of notice_global_symbol) and then IPA or whatever turns it into an alias to
some other symbol.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2015-02-10 15:09 ` jakub at gcc dot gnu.org
@ 2015-02-11 15:10 ` jakub at gcc dot gnu.org
  2015-02-11 15:13 ` jakub at gcc dot gnu.org
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-02-11 15:10 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Wed Feb 11 15:09:48 2015
New Revision: 220625

URL: https://gcc.gnu.org/viewcvs?rev=220625&root=gcc&view=rev
Log:
    PR middle-end/65003
    * varasm.c (place_block_symbol): Assert that DECL_RTL of the
    ultimate alias is MEM with SYMBOL_REF satisfying
    SYMBOL_REF_HAS_BLOCK_INFO_P as its operand.  Don't pass the MEM
    to place_block_symbol, but instead pass the SYMBOL_REF operand of it.

    * g++.dg/opt/pr65003.C: New test.

Added:
    trunk/gcc/testsuite/g++.dg/opt/pr65003.C
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/varasm.c


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (3 preceding siblings ...)
  2015-02-11 15:10 ` jakub at gcc dot gnu.org
@ 2015-02-11 15:13 ` jakub at gcc dot gnu.org
  2015-02-12 13:33 ` ramana at gcc dot gnu.org
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-02-11 15:13 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (4 preceding siblings ...)
  2015-02-11 15:13 ` jakub at gcc dot gnu.org
@ 2015-02-12 13:33 ` ramana at gcc dot gnu.org
  2015-02-12 13:33 ` ramana at gcc dot gnu.org
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: ramana at gcc dot gnu.org @ 2015-02-12 13:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

Ramana Radhakrishnan <ramana at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |doko at gcc dot gnu.org

--- Comment #5 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
*** Bug 65036 has been marked as a duplicate of this bug. ***


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (5 preceding siblings ...)
  2015-02-12 13:33 ` ramana at gcc dot gnu.org
@ 2015-02-12 13:33 ` ramana at gcc dot gnu.org
  2015-02-12 13:34 ` ramana at gcc dot gnu.org
  2015-02-12 13:34 ` ramana at gcc dot gnu.org
  8 siblings, 0 replies; 10+ messages in thread
From: ramana at gcc dot gnu.org @ 2015-02-12 13:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

--- Comment #6 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
*** Bug 65035 has been marked as a duplicate of this bug. ***


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (6 preceding siblings ...)
  2015-02-12 13:33 ` ramana at gcc dot gnu.org
@ 2015-02-12 13:34 ` ramana at gcc dot gnu.org
  2015-02-12 13:34 ` ramana at gcc dot gnu.org
  8 siblings, 0 replies; 10+ messages in thread
From: ramana at gcc dot gnu.org @ 2015-02-12 13:34 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

--- Comment #8 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
*** Bug 65031 has been marked as a duplicate of this bug. ***


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug middle-end/65003] [5 Regression] -fsection-anchors ICE
  2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
                   ` (7 preceding siblings ...)
  2015-02-12 13:34 ` ramana at gcc dot gnu.org
@ 2015-02-12 13:34 ` ramana at gcc dot gnu.org
  8 siblings, 0 replies; 10+ messages in thread
From: ramana at gcc dot gnu.org @ 2015-02-12 13:34 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65003

--- Comment #7 from Ramana Radhakrishnan <ramana at gcc dot gnu.org> ---
*** Bug 65030 has been marked as a duplicate of this bug. ***


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2015-02-12 13:34 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-10 14:29 [Bug middle-end/65003] New: [5 Regression] -fsection-anchors ICE jakub at gcc dot gnu.org
2015-02-10 14:35 ` [Bug middle-end/65003] " jakub at gcc dot gnu.org
2015-02-10 14:36 ` rguenth at gcc dot gnu.org
2015-02-10 15:09 ` jakub at gcc dot gnu.org
2015-02-11 15:10 ` jakub at gcc dot gnu.org
2015-02-11 15:13 ` jakub at gcc dot gnu.org
2015-02-12 13:33 ` ramana at gcc dot gnu.org
2015-02-12 13:33 ` ramana at gcc dot gnu.org
2015-02-12 13:34 ` ramana at gcc dot gnu.org
2015-02-12 13:34 ` ramana at gcc dot gnu.org

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).