public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl
@ 2014-06-08  5:28 ppluzhnikov at google dot com
  2014-06-25 11:18 ` [Bug c++/61445] [4.10 Regression][C++11] " rguenth at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: ppluzhnikov at google dot com @ 2014-06-08  5:28 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 61445
           Summary: [C++11][4.10 Regression] ice in instantiate_decl
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ppluzhnikov at google dot com

This appears to be a recent regression in trunk.
Source reduced from llvm/tools/clang/tools/clang-check/ClangCheck.cpp

Using trunk @r211286:

gcc-svn-r211286/bin/g++ -c t1.ii -std=c++11
t1.ii: In instantiation of ‘void newFrontendActionFactory(FactoryT*,
int*)::A::m_fn1() [with FactoryT = int]’:
t1.ii:18:5:   required from ‘void newFrontendActionFactory(FactoryT*, int*)
[with FactoryT = int]’
t1.ii:19:33:   required from here
t1.ii:11:13: internal compiler error: in instantiate_decl, at cp/pt.c:19753
             B (0, 0);
             ^
0x5c6d0f instantiate_decl(tree_node*, int, bool)
    ../../gcc/cp/pt.c:19752
0x63cda3 mark_used(tree_node*, int)
    ../../gcc/cp/decl2.c:5016
0x557f73 build_over_call
    ../../gcc/cp/call.c:7335
0x563880 build_new_method_call_1
    ../../gcc/cp/call.c:8047
0x563880 build_new_method_call(tree_node*, tree_node*, vec<tree_node*, va_gc,
vl_embed>**, tree_node*, int, tree_node**, int)
    ../../gcc/cp/call.c:8117
0x564959 build_special_member_call(tree_node*, tree_node*, vec<tree_node*,
va_gc, vl_embed>**, tree_node*, int, int)
    ../../gcc/cp/call.c:7661
0x607df6 build_functional_cast(tree_node*, tree_node*, int)
    ../../gcc/cp/typeck2.c:1935
0x5bbf86 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
    ../../gcc/cp/pt.c:14415
0x5ca963 tsubst_expr
    ../../gcc/cp/pt.c:14133
0x5cad61 tsubst_expr
    ../../gcc/cp/pt.c:13559
0x5caf03 tsubst_expr
    ../../gcc/cp/pt.c:13731
0x5c8503 instantiate_decl(tree_node*, int, bool)
    ../../gcc/cp/pt.c:20043
0x5caa2b tsubst_expr
    ../../gcc/cp/pt.c:13872
0x5ca273 tsubst_expr
    ../../gcc/cp/pt.c:13545
0x5caf03 tsubst_expr
    ../../gcc/cp/pt.c:13731
0x5c8503 instantiate_decl(tree_node*, int, bool)
    ../../gcc/cp/pt.c:20043
0x601387 instantiate_pending_templates(int)
    ../../gcc/cp/pt.c:20159
0x63e7ef cp_write_global_declarations()
    ../../gcc/cp/decl2.c:4348
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.

The crash does not reproduce without -std=c++11, nor using trunk build
@r210629.

/// -- cut ---
template < typename FactoryT > void newFrontendActionFactory (FactoryT *, int *
= 0);
int a;

template < typename FactoryT >
void newFrontendActionFactory (FactoryT *, int *)
{
    class A
    {
        void m_fn1 ()
        {
            B (0, 0);
        }
        class B
        {
        public:
            B (FactoryT, int);
        };
    };
    newFrontendActionFactory (&a);
}
>From gcc-bugs-return-453473-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sun Jun 08 05:47:14 2014
Return-Path: <gcc-bugs-return-453473-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 26826 invoked by alias); 8 Jun 2014 05:47:09 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 26653 invoked by uid 55); 8 Jun 2014 05:46:23 -0000
From: "jb at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/56981] Slow I/O: Unformatted 5x slower, large sys component; formatted slow as well
Date: Sun, 08 Jun 2014 05:47:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jb at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-56981-4-y0YBrJZGbw@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-56981-4@http.gcc.gnu.org/bugzilla/>
References: <bug-56981-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-06/txt/msg00555.txt.bz2
Content-length: 1031

https://gcc.gnu.org/bugzilla/show_bug.cgi?idV981

--- Comment #10 from Janne Blomqvist <jb at gcc dot gnu.org> ---
Author: jb
Date: Sun Jun  8 05:43:29 2014
New Revision: 211353

URL: http://gcc.gnu.org/viewcvs?rev!1353&root=gcc&view=rev
Log:
PR 56981 Flush buffer at record boundary if possible.

2014-06-08  Janne Blomqvist  <jb@gcc.gnu.org>

    PR libfortran/56981
    * io/unix.h (struct stream_vtable): Add new member function,
    markeor.
    (smarkeor): New inline function.
    (flush_if_unbuffered): Remove prototype.
    * io/unix.c (raw_markeor): New function.
    (raw_vtable): Initialize markeor member.
    (buf_markeor): New function.
    (buf_vtable): Initialize markeor member.
    (mem_vtable): Likewise.
    (mem4_vtable): Likewise.
    (flush_if_unbuffered): Remove function.
    * io/transfer.c (next_record): Call smarkeor instead of
    flush_if_unbuffered.

Modified:
    trunk/libgfortran/ChangeLog
    trunk/libgfortran/io/transfer.c
    trunk/libgfortran/io/unix.c
    trunk/libgfortran/io/unix.h


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
@ 2014-06-25 11:18 ` rguenth at gcc dot gnu.org
  2014-07-01 15:04 ` [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770 trippels at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-06-25 11:18 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|unknown                     |4.10.0
   Target Milestone|---                         |4.10.0
            Summary|[C++11][4.10 Regression]    |[4.10 Regression][C++11]
                   |ice in instantiate_decl     |ice in instantiate_decl


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
  2014-06-25 11:18 ` [Bug c++/61445] [4.10 Regression][C++11] " rguenth at gcc dot gnu.org
@ 2014-07-01 15:04 ` trippels at gcc dot gnu.org
  2014-07-01 15:51 ` trippels at gcc dot gnu.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: trippels at gcc dot gnu.org @ 2014-07-01 15:04 UTC (permalink / raw)
  To: gcc-bugs

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

Markus Trippelsdorf <trippels at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-07-01
                 CC|                            |trippels at gcc dot gnu.org
      Known to work|                            |4.8.3, 4.9.0
            Summary|[4.10 Regression][C++11]    |[4.10 Regression][C++11]
                   |ice in instantiate_decl     |ice in instantiate_decl at
                   |                            |cp/pt.c:19770
     Ever confirmed|0                           |1
      Known to fail|                            |4.10.0

--- Comment #1 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Just hit the same issue.


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
  2014-06-25 11:18 ` [Bug c++/61445] [4.10 Regression][C++11] " rguenth at gcc dot gnu.org
  2014-07-01 15:04 ` [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770 trippels at gcc dot gnu.org
@ 2014-07-01 15:51 ` trippels at gcc dot gnu.org
  2014-07-14  5:39 ` jason at gcc dot gnu.org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: trippels at gcc dot gnu.org @ 2014-07-01 15:51 UTC (permalink / raw)
  To: gcc-bugs

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

Markus Trippelsdorf <trippels at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-valid-code
                 CC|                            |jason at gcc dot gnu.org

--- Comment #2 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Started with r211094.


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
                   ` (2 preceding siblings ...)
  2014-07-01 15:51 ` trippels at gcc dot gnu.org
@ 2014-07-14  5:39 ` jason at gcc dot gnu.org
  2014-07-14 20:40 ` jason at gcc dot gnu.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2014-07-14  5:39 UTC (permalink / raw)
  To: gcc-bugs

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

Jason Merrill <jason at gcc dot gnu.org> changed:

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


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
                   ` (4 preceding siblings ...)
  2014-07-14 20:40 ` jason at gcc dot gnu.org
@ 2014-07-14 20:40 ` jason at gcc dot gnu.org
  2023-04-27  1:46 ` cvs-commit at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2014-07-14 20:40 UTC (permalink / raw)
  To: gcc-bugs

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

Jason Merrill <jason at gcc dot gnu.org> changed:

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

--- Comment #3 from Jason Merrill <jason at gcc dot gnu.org> ---
Fixed.


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
                   ` (3 preceding siblings ...)
  2014-07-14  5:39 ` jason at gcc dot gnu.org
@ 2014-07-14 20:40 ` jason at gcc dot gnu.org
  2014-07-14 20:40 ` jason at gcc dot gnu.org
  2023-04-27  1:46 ` cvs-commit at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2014-07-14 20:40 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Jason Merrill <jason at gcc dot gnu.org> ---
Author: jason
Date: Mon Jul 14 20:39:35 2014
New Revision: 212524

URL: https://gcc.gnu.org/viewcvs?rev=212524&root=gcc&view=rev
Log:
    PR c++/61445
    PR c++/56947
    * pt.c (instantiate_decl): Don't check defer_ok for local class
    members.

Added:
    trunk/gcc/testsuite/g++.dg/template/local9.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c


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

* [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770
  2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
                   ` (5 preceding siblings ...)
  2014-07-14 20:40 ` jason at gcc dot gnu.org
@ 2023-04-27  1:46 ` cvs-commit at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-04-27  1:46 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Jason Merrill <jason@gcc.gnu.org>:

https://gcc.gnu.org/g:95d4c0d2e6318aef88ba0bc607dfc1ec6b7a612f

commit r14-283-g95d4c0d2e6318aef88ba0bc607dfc1ec6b7a612f
Author: Jason Merrill <jason@redhat.com>
Date:   Thu Mar 16 16:55:39 2023 -0400

    c++: restore instantiate_decl assert

    For PR61445 I removed this assert, but PR108242 demonstrated why it's still
    useful; to avoid regressing the former testcase I check pattern_defined
    in the assert.

    This reverts r212524.

            PR c++/61445

    gcc/cp/ChangeLog:

            * pt.cc (instantiate_decl): Assert !defer_ok for local
            class members.

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

end of thread, other threads:[~2023-04-27  1:46 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-08  5:28 [Bug c++/61445] New: [C++11][4.10 Regression] ice in instantiate_decl ppluzhnikov at google dot com
2014-06-25 11:18 ` [Bug c++/61445] [4.10 Regression][C++11] " rguenth at gcc dot gnu.org
2014-07-01 15:04 ` [Bug c++/61445] [4.10 Regression][C++11] ice in instantiate_decl at cp/pt.c:19770 trippels at gcc dot gnu.org
2014-07-01 15:51 ` trippels at gcc dot gnu.org
2014-07-14  5:39 ` jason at gcc dot gnu.org
2014-07-14 20:40 ` jason at gcc dot gnu.org
2014-07-14 20:40 ` jason at gcc dot gnu.org
2023-04-27  1:46 ` cvs-commit 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).