public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/37189]  New: ICE on valid: OpenMP task construct with implicit firstprivate variables
@ 2008-08-21 13:57 singler at gcc dot gnu dot org
  2008-08-21 13:58 ` [Bug c++/37189] " singler at gcc dot gnu dot org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: singler at gcc dot gnu dot org @ 2008-08-21 13:57 UTC (permalink / raw)
  To: gcc-bugs

Compiling the attached preprocessed source using

g++-rep -march=native -fopenmp -Wall -frounding-math -c task_ice.cpp

gives an ICE.

Compiles fine if c_low is explicitly declared firstprivate in line 126,268 like
this:

#pragma omp task firstprivate(c_low)


-- 
           Summary: ICE on valid: OpenMP task construct with implicit
                    firstprivate variables
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Keywords: openmp
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: singler at gcc dot gnu dot org
 GCC build triplet: x86_64-unknown-linux-gnu
  GCC host triplet: x86_64-unknown-linux-gnu
GCC target triplet: x86_64-unknown-linux-gnu


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


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

* [Bug c++/37189] ICE on valid: OpenMP task construct with implicit firstprivate variables
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
@ 2008-08-21 13:58 ` singler at gcc dot gnu dot org
  2008-08-24 22:54 ` pinskia at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: singler at gcc dot gnu dot org @ 2008-08-21 13:58 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from singler at gcc dot gnu dot org  2008-08-21 13:57 -------
Created an attachment (id=16119)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16119&action=view)
gzip compressed C++ code triggering the ICE


-- 


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


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

* [Bug c++/37189] ICE on valid: OpenMP task construct with implicit firstprivate variables
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
  2008-08-21 13:58 ` [Bug c++/37189] " singler at gcc dot gnu dot org
@ 2008-08-24 22:54 ` pinskia at gcc dot gnu dot org
  2008-08-25  2:04 ` [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-08-24 22:54 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2008-08-24 22:53 -------
Reducing ...


-- 


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
  2008-08-21 13:58 ` [Bug c++/37189] " singler at gcc dot gnu dot org
  2008-08-24 22:54 ` pinskia at gcc dot gnu dot org
@ 2008-08-25  2:04 ` pinskia at gcc dot gnu dot org
  2008-08-25  2:06 ` pinskia at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-08-25  2:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2008-08-25 02:03 -------
Reduced testcase:
struct optional_base  {
  optional_base() {}
  optional_base ( optional_base const& rhs ) {}
};
struct Point_container { optional_base m_b ;  };
int   create_internal_node(Point_container& c)
{
Point_container c_low;  
#pragma omp task
  create_internal_node(c_low);
}


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
  GCC build triplet|x86_64-unknown-linux-gnu    |
   GCC host triplet|x86_64-unknown-linux-gnu    |
 GCC target triplet|x86_64-unknown-linux-gnu    |
           Keywords|                            |ice-on-valid-code
   Last reconfirmed|0000-00-00 00:00:00         |2008-08-25 02:03:16
               date|                            |
            Summary|ICE on valid: OpenMP task   |OpenMP task construct with
                   |construct with implicit     |implicit firstprivate
                   |firstprivate variables      |variables ICEs


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2008-08-25  2:04 ` [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs pinskia at gcc dot gnu dot org
@ 2008-08-25  2:06 ` pinskia at gcc dot gnu dot org
  2008-09-03  7:19 ` singler at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-08-25  2:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from pinskia at gcc dot gnu dot org  2008-08-25 02:05 -------
We are gimplifying the copy constructor while gimplifying something else ...


-- 


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2008-08-25  2:06 ` pinskia at gcc dot gnu dot org
@ 2008-09-03  7:19 ` singler at gcc dot gnu dot org
  2008-09-03  8:14 ` jakub at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: singler at gcc dot gnu dot org @ 2008-09-03  7:19 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from singler at gcc dot gnu dot org  2008-09-03 07:18 -------
To my understanding of the OpenMP standard, a variable not mentioned in the
task pragma is "firstprivate" by default. So stating this fact explicitly
should not change anything, which makes things even stranger.


-- 


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2008-09-03  7:19 ` singler at gcc dot gnu dot org
@ 2008-09-03  8:14 ` jakub at gcc dot gnu dot org
  2008-09-03  9:21 ` jakub at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-09-03  8:14 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from jakub at gcc dot gnu dot org  2008-09-03 08:12 -------
There is nothing strange about it, it is just a bug that needs to be fixed, and
is caused by the design decision that the sharing status of implicitly
determined is computed during the gimplification phase, but synthetization of
method invokes the gimplifier too.  I guess the best fix would be to start
defering all mark_used calls for the duration of finish_function and at the end
of finish_function call all the queued mark_used calls.


-- 


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2008-09-03  8:14 ` jakub at gcc dot gnu dot org
@ 2008-09-03  9:21 ` jakub at gcc dot gnu dot org
  2008-09-03 20:36 ` jakub at gcc dot gnu dot org
  2008-09-03 21:41 ` jakub at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-09-03  9:21 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/2008-
                   |                            |09/msg00203.html
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2008-08-25 02:03:16         |2008-09-03 09:20:07
               date|                            |


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (6 preceding siblings ...)
  2008-09-03  9:21 ` jakub at gcc dot gnu dot org
@ 2008-09-03 20:36 ` jakub at gcc dot gnu dot org
  2008-09-03 21:41 ` jakub at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-09-03 20:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from jakub at gcc dot gnu dot org  2008-09-03 20:34 -------
Subject: Bug 37189

Author: jakub
Date: Wed Sep  3 20:33:21 2008
New Revision: 139955

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=139955
Log:
        PR c++/37189
        * cp-tree.h (defer_mark_used_calls, deferred_mark_used_calls): New
        extern decls.
        * decl2.c (mark_used): If defer_mark_used_calls, push decl into
        deferred_mark_used_calls vector and exit early.
        * decl.c (defer_mark_used_calls, deferred_mark_used_calls): New
        variables.
        (finish_function): Set defer_mark_used_calls for the duration of the
        function.  Call mark_used on any queued decls.

        * g++.dg/gomp/pr37189.C: New test.

Added:
    trunk/gcc/testsuite/g++.dg/gomp/pr37189.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/cp-tree.h
    trunk/gcc/cp/decl.c
    trunk/gcc/cp/decl2.c
    trunk/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs
  2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
                   ` (7 preceding siblings ...)
  2008-09-03 20:36 ` jakub at gcc dot gnu dot org
@ 2008-09-03 21:41 ` jakub at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: jakub at gcc dot gnu dot org @ 2008-09-03 21:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from jakub at gcc dot gnu dot org  2008-09-03 21:39 -------
Fixed.


-- 

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=37189


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

end of thread, other threads:[~2008-09-03 21:41 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-08-21 13:57 [Bug c++/37189] New: ICE on valid: OpenMP task construct with implicit firstprivate variables singler at gcc dot gnu dot org
2008-08-21 13:58 ` [Bug c++/37189] " singler at gcc dot gnu dot org
2008-08-24 22:54 ` pinskia at gcc dot gnu dot org
2008-08-25  2:04 ` [Bug c++/37189] OpenMP task construct with implicit firstprivate variables ICEs pinskia at gcc dot gnu dot org
2008-08-25  2:06 ` pinskia at gcc dot gnu dot org
2008-09-03  7:19 ` singler at gcc dot gnu dot org
2008-09-03  8:14 ` jakub at gcc dot gnu dot org
2008-09-03  9:21 ` jakub at gcc dot gnu dot org
2008-09-03 20:36 ` jakub at gcc dot gnu dot org
2008-09-03 21:41 ` 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).