This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libgomp/52240] New: Using -fopenmp compile some No-OpenMP program, running will receive signal SIGSEGV


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

             Bug #: 52240
           Summary: Using -fopenmp compile some No-OpenMP program, running
                    will receive signal SIGSEGV
    Classification: Unclassified
           Product: gcc
           Version: 4.6.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgomp
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: xunxun1982@gmail.com
              Host: linux, mingw
            Target: linux, mingw


Created attachment 26656
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26656
Using -fopenmp to build this No-OpenMP program

I use -fopenmp to build the test.f90 using gcc 4.6.2
please note: the code is not an OpenMP program

gfortran -O3 -g -fopenmp test.f90 -o test
test running will receive signal SIGSEGV, Linux or mingw toolchains all have
the problem.


Linux gdb log:
----------------------------------------------------------------------------
GNU gdb (Ubuntu/Linaro 7.3-0ubuntu2) 7.3-2011.08
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>...
Reading symbols from /mycode/a.out...done.
(gdb) run
Starting program: /mycode/a.out 

Program received signal SIGSEGV, Segmentation fault.
MAIN__ () at test.f90:6
6    CALL RANDOM_SEED()
(gdb) bt
#0  MAIN__ () at test.f90:6
----------------------------------------------------------------------------


mingw gdb log:
----------------------------------------------------------------------------
GNU gdb (GDB) 7.3
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "mingw32".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from e:\t\test\a.exe...done.
(gdb) run
Starting program: e:\t\test\a.exe 
[New Thread 3364.0x8ac]

Program received signal SIGSEGV, Segmentation fault.
0x0042d223 in __chkstk_ms ()
(gdb) bt
#0  0x0042d223 in __chkstk_ms ()
#1  0x0040166d in MAIN__ () at test.f90:1
----------------------------------------------------------------------------


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]