This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/50564] [4.7 Regression] Front-end optimization - ICE with FORALL
- From: "tkoenig at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 08 Oct 2011 21:41:11 +0000
- Subject: [Bug fortran/50564] [4.7 Regression] Front-end optimization - ICE with FORALL
- Auto-submitted: auto-generated
- References: <bug-50564-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50564
--- Comment #4 from Thomas Koenig <tkoenig at gcc dot gnu.org> 2011-10-08 21:41:11 UTC ---
FORALL sucks rocks through a straw.
We cannot use the usual front-end optimization within forall, because
forall(iTime=1:2)
tmp = dble(iTime)
timeSteps(iTime)=ratio**(tmp-0.5d0)-ratio**(tmp-1.5d0)
end forall
doesn't work (gfortran correctly warns about multiple assignments to tmp).
So, the best method is to disable front-end optimization within
a forall loop.
I assume the same holds for DO CONCURRENT.