[Bug middle-end/31030] New: [Regression 4.3] Segmentation fault of compiled program with -O2

burnus at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Sat Mar 3 12:10:00 GMT 2007


This is with the Polyhedron Fortran Benchmark,
http://www.polyhedron.com/pb05/polyhedron_benchmark_suite.html
http://www.polyhedron.com/pb05/pb05.zip

The test is in ./pb06/lin/source/.

gfortran -g -O1 linpk.f90
./a.out
runs without any error.

gfortran -g -O2 linpk.f90
./a.out
gives a segmentation fault.

Analogously for test_fpu and rnflow.

The regression must have happened between 2007-03-02-r122469 and
2007-03-03-r122499.

valgrind output for linpk.f90 with -O2 (no error for -O1):

==27168== Invalid read of size 8
==27168==    at 0x400CD2: dscal_ (linpk.f90:424)
==27168==    by 0x401C06: dgefa_ (linpk.f90:151)
==27168==    by 0x401DC0: MAIN__ (linpk.f90:14)
==27168==    by 0x40204D: main (fmain.c:18)
==27168==  Address 0x35B7000 is not stack'd, malloc'd or (recently) free'd
==27168==
==27168== Process terminating with default action of signal 11 (SIGSEGV):
dumping core
==27168==  Access not within mapped region at address 0x35B7000
==27168==    at 0x400CD2: dscal_ (linpk.f90:424)
==27168==    by 0x401C06: dgefa_ (linpk.f90:151)
==27168==    by 0x401DC0: MAIN__ (linpk.f90:14)
==27168==    by 0x40204D: main (fmain.c:18)


-- 
           Summary: [Regression 4.3] Segmentation fault of compiled program
                    with -O2
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: middle-end
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: burnus at gcc dot gnu dot org


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



More information about the Gcc-bugs mailing list