public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "vladimir.fuka at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/62131] New: Openmp Regression 4.9.1 : Subobject of an allocatable array not allowed in OMP ATOMIC
Date: Thu, 14 Aug 2014 08:18:00 -0000 [thread overview]
Message-ID: <bug-62131-4@http.gcc.gnu.org/bugzilla/> (raw)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62131
Bug ID: 62131
Summary: Openmp Regression 4.9.1 : Subobject of an allocatable
array not allowed in OMP ATOMIC
Product: gcc
Version: 4.9.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: vladimir.fuka at gmail dot com
layzrc raised this problem on comp.lang.fortran
https://groups.google.com/forum/#!topic/comp.lang.fortran/lVzeHW_X1aw
module storage
integer,allocatable :: nerrs(:,:)
end module
program atomic
use storage
allocate(nerrs(10,10))
!$omp parallel do
do k=1,10
call uperrs(k,1)
enddo
!$omp end parallel do
stop
contains
subroutine uperrs(i,io)
integer,intent(in) :: i,io
!$omp atomic
nerrs(i,io)=nerrs(i,io)+1
end subroutine
end
>gfortran -fopenmp atomic.f90
atomic.f90:18.29:
nerrs(i,io)=nerrs(i,io)+1
1
Error: !$OMP ATOMIC with ALLOCATABLE variable at (1)
I believe this is a wrong and causes a bad regression, because `nerrs(i,io)`
is not an allocatable variable. I believe the section 2.12.6 of OpenMP 4
concerns situations when the whole variable being updated or assigned is
allocatable (e.g. allocatable scalars) and it causes possible re-allocation.
next reply other threads:[~2014-08-14 8:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-14 8:18 vladimir.fuka at gmail dot com [this message]
2014-08-14 13:40 ` [Bug fortran/62131] [4.9.1 Regression] OpenMP: " burnus at gcc dot gnu.org
2014-08-14 16:24 ` [Bug fortran/62131] [4.9/5 " jakub at gcc dot gnu.org
2014-08-15 10:23 ` jakub at gcc dot gnu.org
2014-08-15 10:24 ` jakub at gcc dot gnu.org
2014-10-02 12:55 ` jakub at gcc dot gnu.org
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-62131-4@http.gcc.gnu.org/bugzilla/ \
--to=gcc-bugzilla@gcc.gnu.org \
--cc=gcc-bugs@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).