public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/60198] New: ICE with _Cilk_spawn in expression within template function
@ 2014-02-14 15:35 reichelt at gcc dot gnu.org
  2014-02-14 15:36 ` [Bug c++/60198] " reichelt at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: reichelt at gcc dot gnu.org @ 2014-02-14 15:35 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 60198
           Summary: ICE with _Cilk_spawn in expression within template
                    function
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: reichelt at gcc dot gnu.org

The following valid(?) code snippet (compiled with "-fcilkplus") triggers
an ICE on trunk:

===========================================
template<typename T> int foo()
{
  int i = (_Cilk_spawn foo<T>()) + 0;
  return i;
}

template int foo<int>();
===========================================

bug.cc: In instantiation of 'int foo() [with T = int]':
bug.cc:7:23:   required from here
bug.cc:3:31: internal compiler error: in tsubst_copy, at cp/pt.c:12887
   int i = (_Cilk_spawn foo<T>()) + 0;
                               ^
0x62a933 tsubst_copy
        ../../gcc/gcc/cp/pt.c:12887
0x607956 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc/gcc/cp/pt.c:15110
0x608fda tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc/gcc/cp/pt.c:14188
0x6115c6 tsubst_expr
        ../../gcc/gcc/cp/pt.c:13812
0x61435d tsubst_expr
        ../../gcc/gcc/cp/pt.c:13327
0x611093 tsubst_expr
        ../../gcc/gcc/cp/pt.c:13219
0x61208c tsubst_expr
        ../../gcc/gcc/cp/pt.c:13424
0x60f2a9 instantiate_decl(tree_node*, int, bool)
        ../../gcc/gcc/cp/pt.c:19690
0x64d8c7 instantiate_pending_templates(int)
        ../../gcc/gcc/cp/pt.c:19806
0x688bed cp_write_global_declarations()
        ../../gcc/gcc/cp/decl2.c:4148
Please submit a full bug report, [etc.]


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

end of thread, other threads:[~2015-05-01  8:37 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-14 15:35 [Bug c++/60198] New: ICE with _Cilk_spawn in expression within template function reichelt at gcc dot gnu.org
2014-02-14 15:36 ` [Bug c++/60198] " reichelt at gcc dot gnu.org
2014-02-18 10:14 ` slayoo at staszic dot waw.pl
2014-02-18 14:20 ` bviyer at gmail dot com
2014-02-18 23:00 ` slayoo at staszic dot waw.pl
2015-02-10  6:22 ` pinskia at gcc dot gnu.org
2015-02-10  6:38 ` pinskia at gcc dot gnu.org
2015-05-01  8:37 ` hvdieren at elis dot ugent.be

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