public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/27328]  New: ICE with -fopenmp and goto
@ 2006-04-26 16:13 reichelt at gcc dot gnu dot org
  2006-04-26 16:36 ` [Bug middle-end/27328] " pinskia at gcc dot gnu dot org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2006-04-26 16:13 UTC (permalink / raw)
  To: gcc-bugs

The following testcase causes an ICE (segfault in remove_exit_barriers
from tree-flow-inline.h) when compiles with -fopenmp:

=========================
void foo()
{
#pragma omp parallel
  {
    L1:
    goto L1;
  }
}
=========================


-- 
           Summary: ICE with -fopenmp and goto
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, monitored, openmp
          Severity: normal
          Priority: P3
         Component: middle-end
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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


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

* [Bug middle-end/27328] ICE with -fopenmp and goto
  2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
@ 2006-04-26 16:36 ` pinskia at gcc dot gnu dot org
  2006-04-27 15:39 ` jakub at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-04-26 16:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2006-04-26 16:36 -------
Confirmed.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2006-04-26 16:36:23
               date|                            |


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


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

* [Bug middle-end/27328] ICE with -fopenmp and goto
  2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
  2006-04-26 16:36 ` [Bug middle-end/27328] " pinskia at gcc dot gnu dot org
@ 2006-04-27 15:39 ` jakub at gcc dot gnu dot org
  2006-04-28  9:29 ` jakub at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2006-04-27 15:39 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from jakub at gcc dot gnu dot org  2006-04-27 15:38 -------
This is not specific to goto, any OMP structured block which the initial cfg
pass proves it will never return is a problem.  In that case, the corresponding
OMP_RETURN is optimized out as unreachable.  The first ICE is fairly easy
to fix:
--- omp-low.c.jj2       2006-04-27 16:35:04.000000000 +0200
+++ omp-low.c   2006-04-27 17:29:32.000000000 +0200
@@ -2231,6 +2231,11 @@ remove_exit_barrier (struct omp_region *

   exit_bb = region->exit;

+  /* If the parallel region doesn't return, we don't have REGIOn->EXIT
+     block at all.  */
+  if (! exit_bb)
+    return;
+
   /* The last insn in the block will be the parallel's OMP_RETURN.  The
      workshare's OMP_RETURN will be in a preceding block.  The kinds of
      statements that can appear in between are extremely limited -- no
but with this, we ICE in move_sese_region_to_fn and there it will be harder
to deal with it.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rth at gcc dot gnu dot org,
                   |                            |dnovillo at gcc dot gnu dot
                   |                            |org


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


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

* [Bug middle-end/27328] ICE with -fopenmp and goto
  2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
  2006-04-26 16:36 ` [Bug middle-end/27328] " pinskia at gcc dot gnu dot org
  2006-04-27 15:39 ` jakub at gcc dot gnu dot org
@ 2006-04-28  9:29 ` jakub at gcc dot gnu dot org
  2006-05-02 10:41 ` jakub at gcc dot gnu dot org
  2006-05-02 10:47 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2006-04-28  9:29 UTC (permalink / raw)
  To: gcc-bugs



-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jakub at gcc dot gnu dot org
                   |dot org                     |
                URL|                            |http://gcc.gnu.org/ml/gcc-
                   |                            |patches/2006-
                   |                            |04/msg01080.html
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2006-04-26 16:36:23         |2006-04-28 09:29:51
               date|                            |


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


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

* [Bug middle-end/27328] ICE with -fopenmp and goto
  2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2006-04-28  9:29 ` jakub at gcc dot gnu dot org
@ 2006-05-02 10:41 ` jakub at gcc dot gnu dot org
  2006-05-02 10:47 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2006-05-02 10:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from jakub at gcc dot gnu dot org  2006-05-02 10:41 -------
Subject: Bug 27328

Author: jakub
Date: Tue May  2 10:41:44 2006
New Revision: 113455

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=113455
Log:
        PR middle-end/27328
        * omp-low.c (remove_exit_barrier): Handle NULL exit_bb.
        (expand_omp_parallel): Likewise.
        * tree-cfg.c (move_sese_region_to_fn): Likewise.

        * gcc.dg/gomp/pr27328.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/gomp/pr27328.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/omp-low.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-cfg.c


-- 


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


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

* [Bug middle-end/27328] ICE with -fopenmp and goto
  2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2006-05-02 10:41 ` jakub at gcc dot gnu dot org
@ 2006-05-02 10:47 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2006-05-02 10:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from jakub at gcc dot gnu dot org  2006-05-02 10:47 -------
Fixed in SVN.


-- 

jakub at gcc dot gnu dot org changed:

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


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


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

end of thread, other threads:[~2006-05-02 10:47 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-04-26 16:13 [Bug middle-end/27328] New: ICE with -fopenmp and goto reichelt at gcc dot gnu dot org
2006-04-26 16:36 ` [Bug middle-end/27328] " pinskia at gcc dot gnu dot org
2006-04-27 15:39 ` jakub at gcc dot gnu dot org
2006-04-28  9:29 ` jakub at gcc dot gnu dot org
2006-05-02 10:41 ` jakub at gcc dot gnu dot org
2006-05-02 10:47 ` jakub at gcc dot gnu dot 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).