public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326
@ 2014-10-18  4:46 jaredhoberock at gmail dot com
  2014-10-18 11:41 ` [Bug c++/63584] [4.8/4.9 Regression] " trippels at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: jaredhoberock at gmail dot com @ 2014-10-18  4:46 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 3855 bytes --]

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

            Bug ID: 63584
           Summary: ICE in strip_typedefs, at cp/tree.c:1326
           Product: gcc
           Version: 4.9.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jaredhoberock at gmail dot com

The attached preprocessed source produces the following compiler error message:


$ g++ -std=c++11 -pthread preprocessed_repro.cpp 
‘
In file included from test_nested_executor.cpp:3:0:
in strip_typedefs, at cp/tree.c:1326
         auto inner_lambda = inner_lambda_gcc49_workaround<outer_index_type,
outer_shared_ref_type>{outer_idx, outer_shared_ref};
                                                                               
                                               ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.9/README.Bugs> for instructions.
Preprocessed source stored into /tmp/ccSYvoB9.out file, please attach this to
your bugreport.



I believe this is a regression because g++4.8.2-19ubuntu1 compiles the same
code which executes as expected.

System details:

$ g++ --version ; echo ; uname -a ; echo ; cat /etc/lsb-release 
g++ (Ubuntu 4.9.1-3ubuntu2~14.04.1) 4.9.1
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


Linux jhoberock-dt-fixme 3.13.0-32-generic #57-Ubuntu SMP Tue Jul 15 03:51:08
UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=14.04
DISTRIB_CODENAME=trusty
DISTRIB_DESCRIPTION="Ubuntu 14.04.1 LTS"
>From gcc-bugs-return-464399-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Oct 18 04:47:31 2014
Return-Path: <gcc-bugs-return-464399-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 4832 invoked by alias); 18 Oct 2014 04:47:30 -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 4808 invoked by uid 48); 18 Oct 2014 04:47:27 -0000
From: "jaredhoberock at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/63584] ICE in strip_typedefs, at cp/tree.c:1326
Date: Sat, 18 Oct 2014 04:47:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jaredhoberock at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
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: attachments.created
Message-ID: <bug-63584-4-QrxarPA4xf@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-63584-4@http.gcc.gnu.org/bugzilla/>
References: <bug-63584-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-10/txt/msg01420.txt.bz2
Content-length: 242

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

--- Comment #1 from jaredhoberock at gmail dot com ---
Created attachment 33753
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id3753&actioníit
preprocessed output of ICE reproducer


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

* [Bug c++/63584] [4.8/4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
@ 2014-10-18 11:41 ` trippels at gcc dot gnu.org
  2014-12-10 13:15 ` rguenth at gcc dot gnu.org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: trippels at gcc dot gnu.org @ 2014-10-18 11:41 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-10-18
                 CC|                            |trippels at gcc dot gnu.org
      Known to work|                            |5.0
   Target Milestone|---                         |4.8.5
            Summary|ICE in strip_typedefs, at   |[4.8/4.9 Regression] ICE in
                   |cp/tree.c:1326              |strip_typedefs, at
                   |                            |cp/tree.c:1326
     Ever confirmed|0                           |1
      Known to fail|                            |4.8.3, 4.9.1

--- Comment #2 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
 ~ % cat preprocessed_repro.ii
namespace std
{
template <typename _Tp, _Tp __v> struct A
{
  static constexpr _Tp value = __v;
};
typedef A<bool, false> false_type;
template <typename> void declval ();
struct __add_lvalue_reference_helper
{
  typedef int type;
};
int make_tuple ();
template <bool, typename, typename> struct __lazy_conditional;
template <typename T, typename F> struct __lazy_conditional<false, T, F>
{
  using type = typename F::type;
};
template <class Executor> struct B
{
  using execution_category = typename Executor::execution_category;
  using shape_type = struct tuple_of_references_t;
  template <class>
  struct C : __lazy_conditional<false_type::value, tuple_of_references_t,
                                __add_lvalue_reference_helper>
  {
  };
  template <class T> using shared_param_type = typename C<T>::type;
};
template <class, class T>
auto __make_tuple_if_not_nested (T) -> decltype (make_tuple ());
template <class Executor1, class Executor2> class D
{
  using outer_executor_type = Executor1;
  using inner_executor_type = Executor2;
  using outer_traits = B<outer_executor_type>;
  using inner_traits = B<inner_executor_type>;
  using inner_execution_category = typename inner_traits::execution_category;
  using outer_index_type = typename outer_traits::shape_type;
  using inner_shape_type = typename inner_traits::shape_type;

public:
  using shape_type
      = decltype (__make_tuple_if_not_nested<inner_execution_category> (
          declval<inner_shape_type>));
  template <class, class> struct inner_lambda_gcc49_workaround
  {
  };
  template <class Function, class Tuple>
  void
  bulk_async (Function, shape_type, Tuple shared_arg_tuple)
  {
    auto outer_shared_arg (shared_arg_tuple);
    using outer_shared_ref_type =
        typename outer_traits::template shared_param_type<decltype (
            outer_shared_arg)>;
    []
    {
      inner_lambda_gcc49_workaround<outer_index_type, outer_shared_ref_type>{};
    };
  }
};
class F
{
public:
  using execution_category = int;
};
}
main ()
{
  std::D<std::F, std::F> ex2;
  ex2.bulk_async ([]
                  {
                  },
                  std::make_tuple (), std::make_tuple);
}


 ~ % g++ -c -O0 -std=c++11 preprocessed_repro.ii
preprocessed_repro.ii: In instantiation of 'std::D<Executor1,
Executor2>::bulk_async(Function, std::D<Executor1, Executor2>::shape_type,
Tuple)::<lambda()> [with Function = main()::<lambda()>; Tuple = int (*)();
Executor1 = std::F; Executor2 = std::F]':
preprocessed_repro.ii:57:6:   required from 'struct std::D<Executor1,
Executor2>::bulk_async(Function, std::D<Executor1, Executor2>::shape_type,
Tuple) [with Function = main()::<lambda()>; Tuple = int (*)(); Executor1 =
std::F; Executor2 = std::F; std::D<Executor1, Executor2>::shape_type = int;
std::D<Executor1, Executor2>::inner_execution_category = int; std::D<Executor1,
Executor2>::inner_shape_type = std::tuple_of_references_t]::<lambda()>'
preprocessed_repro.ii:57:5:   required from 'void std::D<Executor1,
Executor2>::bulk_async(Function, std::D<Executor1, Executor2>::shape_type,
Tuple) [with Function = main()::<lambda()>; Tuple = int (*)(); Executor1 =
std::F; Executor2 = std::F; std::D<Executor1, Executor2>::shape_type = int;
std::D<Executor1, Executor2>::inner_execution_category = int; std::D<Executor1,
Executor2>::inner_shape_type = std::tuple_of_references_t]'
preprocessed_repro.ii:75:54:   required from here
preprocessed_repro.ii:59:7: internal compiler error: in strip_typedefs, at
cp/tree.c:1326
       inner_lambda_gcc49_workaround<outer_index_type,
outer_shared_ref_type>{};
       ^
0x6118b7 strip_typedefs(tree_node*)
        ../../gcc-4.9.1-src/gcc/cp/tree.c:1326
0x558e4c canonicalize_type_argument
        ../../gcc-4.9.1-src/gcc/cp/pt.c:6349
0x5672e0 coerce_template_parms
        ../../gcc-4.9.1-src/gcc/cp/pt.c:7002
0x56ba4a lookup_template_class_1
        ../../gcc-4.9.1-src/gcc/cp/pt.c:7551
0x56ba4a lookup_template_class(tree_node*, tree_node*, tree_node*, tree_node*,
int, int)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:7886
0x56dbe7 tsubst_aggr_type
        ../../gcc-4.9.1-src/gcc/cp/pt.c:10196
0x568493 tsubst(tree_node*, tree_node*, int, tree_node*)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:11604
0x5612f6 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:15075
0x5656ff tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:14016
0x5647af tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:13432
0x5656cd tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:13623
0x5656cd tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:13623
0x564402 instantiate_decl(tree_node*, int, bool)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:19922
0x579d11 instantiate_class_template_1
        ../../gcc-4.9.1-src/gcc/cp/pt.c:9367
0x579d11 instantiate_class_template(tree_node*)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:9435
0x5cfffd complete_type(tree_node*)
        ../../gcc-4.9.1-src/gcc/cp/typeck.c:134
0x560db6 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-4.9.1-src/gcc/cp/pt.c:15284
0x5656ff tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:14016
0x5647af tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:13432
0x564fd4 tsubst_expr
        ../../gcc-4.9.1-src/gcc/cp/pt.c:13418
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.


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

* [Bug c++/63584] [4.8/4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
  2014-10-18 11:41 ` [Bug c++/63584] [4.8/4.9 Regression] " trippels at gcc dot gnu.org
@ 2014-12-10 13:15 ` rguenth at gcc dot gnu.org
  2014-12-19 13:31 ` jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-10 13:15 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-valid-code
           Priority|P3                          |P2
   Target Milestone|4.8.5                       |4.8.4


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

* [Bug c++/63584] [4.8/4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
  2014-10-18 11:41 ` [Bug c++/63584] [4.8/4.9 Regression] " trippels at gcc dot gnu.org
  2014-12-10 13:15 ` rguenth at gcc dot gnu.org
@ 2014-12-19 13:31 ` jakub at gcc dot gnu.org
  2015-06-23  8:26 ` rguenth at gcc dot gnu.org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2014-12-19 13:31 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.8.4                       |4.8.5

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.8.4 has been released.


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

* [Bug c++/63584] [4.8/4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
                   ` (2 preceding siblings ...)
  2014-12-19 13:31 ` jakub at gcc dot gnu.org
@ 2015-06-23  8:26 ` rguenth at gcc dot gnu.org
  2015-06-26 19:59 ` [Bug c++/63584] [4.9 " jakub at gcc dot gnu.org
  2015-06-26 20:39 ` jakub at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2015-06-23  8:26 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.8.5                       |4.9.3

--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
The gcc-4_8-branch is being closed, re-targeting regressions to 4.9.3.


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

* [Bug c++/63584] [4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
                   ` (3 preceding siblings ...)
  2015-06-23  8:26 ` rguenth at gcc dot gnu.org
@ 2015-06-26 19:59 ` jakub at gcc dot gnu.org
  2015-06-26 20:39 ` jakub at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-06-26 19:59 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.9.3 has been released.


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

* [Bug c++/63584] [4.9 Regression] ICE in strip_typedefs, at cp/tree.c:1326
  2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
                   ` (4 preceding siblings ...)
  2015-06-26 19:59 ` [Bug c++/63584] [4.9 " jakub at gcc dot gnu.org
@ 2015-06-26 20:39 ` jakub at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-06-26 20:39 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.9.3                       |4.9.4


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

end of thread, other threads:[~2015-06-26 20:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-18  4:46 [Bug c++/63584] New: ICE in strip_typedefs, at cp/tree.c:1326 jaredhoberock at gmail dot com
2014-10-18 11:41 ` [Bug c++/63584] [4.8/4.9 Regression] " trippels at gcc dot gnu.org
2014-12-10 13:15 ` rguenth at gcc dot gnu.org
2014-12-19 13:31 ` jakub at gcc dot gnu.org
2015-06-23  8:26 ` rguenth at gcc dot gnu.org
2015-06-26 19:59 ` [Bug c++/63584] [4.9 " jakub at gcc dot gnu.org
2015-06-26 20:39 ` jakub 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).