Summary: | ICE: OpenMP: when combining shared() and a move constructor | ||
---|---|---|---|
Product: | gcc | Reporter: | Jim Radford <radford> |
Component: | c++ | Assignee: | Not yet assigned to anyone <unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | jakub |
Priority: | P3 | Keywords: | openmp |
Version: | 4.7.2 | ||
Target Milestone: | --- | ||
Host: | Target: | ||
Build: | Known to work: | ||
Known to fail: | Last reconfirmed: | 2013-02-06 00:00:00 |
Description
Jim Radford
2013-02-06 04:44:01 UTC
Confirmed. On trunk we ICE with t.C: In function 'ptr<int> f()': t.C:15:15: error: invalid conversion in return statement return pt; ^ struct ptr struct ptr & return pt.5; t.C:15:15: internal compiler error: verify_gimple failed 0xcfd441 verify_gimple_in_cfg(function*) /space/rguenther/src/svn/trunk/gcc/tree-cfg.c:4747 Author: jakub Date: Wed Feb 6 10:34:53 2013 New Revision: 195796 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=195796 Log: PR middle-end/56217 * omp-low.c (use_pointer_for_field): Return false if lower_send_shared_vars doesn't generate any copy-out code. * g++.dg/gomp/pr56217.C: New test. * testsuite/libgomp.c++/pr56217.C: New test. Added: trunk/gcc/testsuite/g++.dg/gomp/pr56217.C trunk/libgomp/testsuite/libgomp.c++/pr56217.C Modified: trunk/gcc/ChangeLog trunk/gcc/omp-low.c trunk/gcc/testsuite/ChangeLog trunk/libgomp/ChangeLog Should be fixed on the trunk so far. Note your testcase is invalid, without the taskwait I've added, it relies on NRV and even with NRV, by the time the task can run the temporary result of f() can be destructed already. (In reply to comment #3) > Should be fixed on the trunk Thanks! > Note your testcase is invalid, without > the taskwait I've added, it relies on NRV and even with NRV, by the time the > task can run the temporary result of f() can be destructed already. I had the taskwait in my original. Still, thanks for the explanation; it adds to my nascent mental model of openmp. Maybe one day I'll get something to compile so I can try it out, but first I'm off to compile gcc! Author: jakub Date: Tue Feb 19 17:19:36 2013 New Revision: 196141 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=196141 Log: Backported from mainline 2013-02-06 Jakub Jelinek <jakub@redhat.com> PR middle-end/56217 * omp-low.c (use_pointer_for_field): Return false if lower_send_shared_vars doesn't generate any copy-out code. * g++.dg/gomp/pr56217.C: New test. * testsuite/libgomp.c++/pr56217.C: New test. Added: branches/gcc-4_7-branch/gcc/testsuite/g++.dg/gomp/pr56217.C branches/gcc-4_7-branch/libgomp/testsuite/libgomp.c++/pr56217.C Modified: branches/gcc-4_7-branch/gcc/ChangeLog branches/gcc-4_7-branch/gcc/omp-low.c branches/gcc-4_7-branch/gcc/testsuite/ChangeLog branches/gcc-4_7-branch/libgomp/ChangeLog Fixed for 4.7.3+. |