This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/43829] Scalarization of reductions
- From: "paul.richard.thomas at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 09 Oct 2011 09:48:00 +0000
- Subject: [Bug fortran/43829] Scalarization of reductions
- Auto-submitted: auto-generated
- References: <bug-43829-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43829
--- Comment #44 from paul.richard.thomas at gmail dot com <paul.richard.thomas at gmail dot com> 2011-10-09 09:48:00 UTC ---
Dear Mikael,
I have duly loaded up your patch - it looks very slick and
professional; it even works as intended!
>>
> This is included in the patch in comment #41. Unfortunately, it makes the test
> (comment #42) fail with -Os in the testsuite. I don't know yet how I will
> handle it. I would like to avoid forcing one optimization level if possible.
> Any idea?
I confirm you finding:
FAIL: gfortran.dg/function_optimize_7.f90 -O scan-tree-dump-times
original "sum_r4" 1
FAIL: gfortran.dg/inline_sum_1.f90 -Os (test for excess errors)
FAIL: gfortran.dg/select_type_12.f03 -O (internal compiler error)
FAIL: gfortran.dg/select_type_12.f03 -O (test for excess errors)
Running /svn/trunk/gcc/testsuite/gfortran.dg/gomp/gomp.exp ...
Running /svn/trunk/gcc/testsuite/gfortran.dg/graphite/graphite.exp ...
Running /svn/trunk/gcc/testsuite/gfortran.dg/guality/guality.exp ...
Running /svn/trunk/gcc/testsuite/gfortran.dg/lto/lto.exp ...
Running /svn/trunk/gcc/testsuite/gfortran.dg/vect/vect.exp ...
Running /svn/trunk/gcc/testsuite/gfortran.fortran-torture/compile/compile.exp
...
Running /svn/trunk/gcc/testsuite/gfortran.fortran-torture/execute/execute.exp
...
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O2
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O2
-fomit-frame-pointer -finline-functions
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O2
-fomit-frame-pointer -finline-functions -funroll-loops
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O2
-fbounds-check
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O3 -g
FAIL: gfortran.fortran-torture/execute/entry_4.f90 execution, -O2
-ftree-vectorize -msse2
The function_optimize_7.f90 failure is obviously trivial. Both the
select_type_12.f03 and the entry_4.f90 failures have crept in during
the last few days and appear to be some middle-end fault.
As for your inline_sum_1.f90: The failure here is dues to extra
temporary array warnings with -Os. I tried switching on and off the
extra optimizations in Os versus O2 but could not identify the
culprit. That said, the test runs correctly with -Os.
What I would do is to double up the test; one with { dg-do compile }
and -Warray-temporaries and trhe other with { dg-do run } only.
Cheers
Paul