[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #11 from reichelt at gcc dot gnu dot org 2008-03-29 17:32 --- *** Bug 35596 has been marked as a duplicate of this bug. *** -- reichelt at gcc dot gnu dot org changed: What|Removed |Added CC||kevin at kelphead dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #10 from reichelt at gcc dot gnu dot org 2007-11-01 12:52 --- Nathan confirmed in private mail that the compiler now does the right thing. So closing as fixed. -- reichelt at gcc dot gnu dot org changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED Target Milestone|--- |4.3.0 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #8 from reichelt at gcc dot gnu dot org 2007-07-23 22:05 --- Since Nathan's patch for PR32839, we get the following error message for the testcase in comment #7 (and similar messages for the original testcase, the testcase in comment #6, and PR 24606): bug.cc: In function 'void foo(F) [with F = void (*)(A)]': bug.cc:16: instantiated from here bug.cc:3: error: too few arguments to function I get the same error message if I make bar a non-template function. In contrast to my last sentence of comment #7, I now think the compiler does the right thing here. Nathan, do you think so, too? If yes, we can close this bug as fixed. -- reichelt at gcc dot gnu dot org changed: What|Removed |Added CC||nathan at gcc dot gnu dot ||org Keywords|ice-on-valid-code |ice-on-invalid-code http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #9 from reichelt at gcc dot gnu dot org 2007-07-23 22:08 --- *** Bug 24606 has been marked as a duplicate of this bug. *** -- Bug 24602 depends on bug 24606, which changed state. Bug 24606 Summary: ICE on template function which gets an template agrument as a function with a default argument http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24606 What|Old Value |New Value Status|NEW |RESOLVED Resolution||DUPLICATE http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #7 from reichelt at gcc dot gnu dot org 2005-11-17 11:59 --- Here's a sightly simpler testcase. If I remove the copy-ctor from A, I get the failure from PR24606. = templatetypename F void foo(F f) { f(); } struct A { A(); A(const A); }; templateint void bar(A = A()); void baz() { foo(bar0); } = Btw, removing the template from bar makes the code compile. So it seems like the code is valid after all. -- reichelt at gcc dot gnu dot org changed: What|Removed |Added CC||reichelt at gcc dot gnu dot ||org Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Keywords||ice-on-valid-code, monitored Last reconfirmed|-00-00 00:00:00 |2005-11-17 11:59:15 date|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #1 from xeon at gmx dot ch 2005-10-31 23:46 --- Created an attachment (id=10092) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=10092action=view) preprocessed source file -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #2 from pinskia at gcc dot gnu dot org 2005-11-01 00:33 --- This is a true C++ front-end problem, in that the seg fault is due to a stack overflow in the C++ front-end. I think this is a regression but I have not tried to reduce it yet. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #3 from pinskia at gcc dot gnu dot org 2005-11-01 02:22 --- With the source here, I was able to find a different issue which I will be posting soon. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #4 from pinskia at gcc dot gnu dot org 2005-11-01 02:23 --- Note the backtrace for the orginal issue is: #28 0x0040bb94 in convert_like_real (convs=Variable convs is not available. ) at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:4379 #29 0x0040c241 in build_over_call (cand=0x15009b8, flags=1067) at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:4804 #30 0x0040aacd in build_new_method_call (instance=0x2dbb4a40, fns=Variable fns is not available. ) at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:5441 #31 0x0040b5fa in convert_like_real (convs=0x15006e8, expr=0x2bf002c0, fn=0x2bacd100, argnum=0, inner=-1, issue_conversion_warnings=0 '\0', c_cast_p=0 '\0') at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:4293 #32 0x0040b71e in convert_like_real (convs=0x1500710, expr=0x2bf002c0, fn=0x2bacd100, argnum=0, inner=0, issue_conversion_warnings=1 '\001', c_cast_p=0 '\0') at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:4304 #33 0x0040c241 in build_over_call (cand=0x1500738, flags=3) at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:4804 #34 0x0040aacd in build_new_method_call (instance=0x2dbb49c0, fns=Variable fns is not available. ) at /home/pinskia/src/newtest/trunk/gcc/cp/call.c:5441 #35 0x004b5c9f in ocp_convert (type=0x2bab5420, expr=0x2bf002c0, convtype=Variable convtype is not available. ) at /home/pinskia/src/newtest/trunk/gcc/cp/cvt.c:764 # -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #5 from pinskia at gcc dot gnu dot org 2005-11-01 03:09 --- PR 24606 is the other issue I found. -- pinskia at gcc dot gnu dot org changed: What|Removed |Added BugsThisDependsOn||24606 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602
[Bug c++/24602] g++: Internal error: Illegal instruction (program cc1plus)
--- Comment #6 from pinskia at gcc dot gnu dot org 2005-11-01 04:36 --- Reduced testcase: struct string; struct _Deque_iterator { string operator*() const; }; templatetypename _Function void for_each(_Function __f) { _Deque_iterator __first1; __f(*__first1); } struct locale { locale(const locale __other) throw(); }; templatetypename SequenceT void trim(string Input, const locale Loc=locale()); int main() { for_each(trimstring); } This one also ICEs with ICC. I will let someone else decide if this is valid or invalid code and then confirm it. -- pinskia at gcc dot gnu dot org changed: What|Removed |Added CC||pinskia at gcc dot gnu dot ||org Known to fail||2.95.3 3.3.3 3.4.0 4.0.0 ||4.1.0 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24602