public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/60522] New: WHERE construct causes an ICE in gfc_trans_where_2
@ 2014-03-14  8:15 roger.ferrer at bsc dot es
  2014-03-14 19:14 ` [Bug fortran/60522] [4.7/4.8/4.9 Regression] " dominiq at lps dot ens.fr
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: roger.ferrer at bsc dot es @ 2014-03-14  8:15 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 60522
           Summary: WHERE construct causes an ICE in gfc_trans_where_2
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: roger.ferrer at bsc dot es

Hi,

the following code

! -- test.f90
subroutine foo(a, b)
   implicit none
   integer, dimension(:), intent(inout) :: a
   integer, dimension(:), intent(in) :: b

   where (b(:) > 0)
      a(lbound(a, 1):ubound(a, 1)) = b(lbound(b, 1):ubound(b, 1)) * b(lbound(b,
1):ubound(b, 1))
   end where
end subroutine foo
! -- end of test.f90

causes an ICE if optimization is enabled:

$ gfortran -c test.f90 -O
test.f90: In function ‘foo’:
test.f90:6:0: internal compiler error: in gfc_trans_where_2, at
fortran/trans-stmt.c:4550
    where (B(:) > 0)
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.8/README.Bugs> for instructions.

The problem goes away if the assignment is of the (equivalent) form:

 a(:) = b(:) * b(:)

or

 a = b * b

or if optimization is disabled.

Kind regards,
>From gcc-bugs-return-446262-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri Mar 14 08:18:32 2014
Return-Path: <gcc-bugs-return-446262-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 21874 invoked by alias); 14 Mar 2014 08:18:32 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 21849 invoked by uid 48); 14 Mar 2014 08:18:28 -0000
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/60521] std::lock_guard ignores adopt_lock strategy
Date: Fri, 14 Mar 2014 08:18:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: libstdc++
X-Bugzilla-Version: 4.8.3
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: redi at gcc dot gnu.org
X-Bugzilla-Status: WAITING
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on everconfirmed bug_severity
Message-ID: <bug-60521-4-KGn6QDAbzj@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-60521-4@http.gcc.gnu.org/bugzilla/>
References: <bug-60521-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-03/txt/msg01131.txt.bz2
Content-length: 735

http://gcc.gnu.org/bugzilla/show_bug.cgi?id`521

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
   Last reconfirmed|                            |2014-03-14
     Ever confirmed|0                           |1
           Severity|blocker                     |normal

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(In reply to Sergei Turchanov from comment #0)
>       lock_guard(mutex_type& __m, adopt_lock_t) : _M_device(__m)
>       { } // calling thread owns mutex

Where in that code do you think it locks the mutex?


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

end of thread, other threads:[~2014-03-29 11:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-14  8:15 [Bug fortran/60522] New: WHERE construct causes an ICE in gfc_trans_where_2 roger.ferrer at bsc dot es
2014-03-14 19:14 ` [Bug fortran/60522] [4.7/4.8/4.9 Regression] " dominiq at lps dot ens.fr
2014-03-14 20:20 ` mikael at gcc dot gnu.org
2014-03-14 23:24 ` tkoenig at gcc dot gnu.org
2014-03-27 22:22 ` tkoenig at gcc dot gnu.org
2014-03-28  7:17 ` tkoenig at gcc dot gnu.org
2014-03-29 11:51 ` tkoenig at gcc dot gnu.org
2014-03-29 11:53 ` tkoenig at gcc dot gnu.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).