public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/105182] New: compiling NJOY21 causes a ICE segmentation fault: 11
@ 2022-04-06 15:59 kermitnuc at gmail dot com
  2022-04-06 17:06 ` [Bug fortran/105182] " kargl at gcc dot gnu.org
                   ` (18 more replies)
  0 siblings, 19 replies; 20+ messages in thread
From: kermitnuc at gmail dot com @ 2022-04-06 15:59 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105182

            Bug ID: 105182
           Summary: compiling NJOY21 causes a ICE segmentation fault: 11
           Product: gcc
           Version: 11.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: kermitnuc at gmail dot com
  Target Milestone: ---

GCC 10.3 compiles NJOY21 without issue.  GCC 11.1 and 11.2 do not.  

GCC configure script:
/configure  --prefix=/usr/local/gcc-1030 --enable-languages=c,c++,fortran,lto
CC=/usr/bin/gcc CXX=/usr/bin/g++ LD=/usr/bin/ld  --with-gmp=/usr/local
--with-mpfr=/usr/local  --with-mpc=/usr/local --with-isl=/usr/local
--with-libiconv-prefix=/usr/local --with-libiconv=/usr/local --with-system-zlib
--with-native-system-header-dir=/usr/include --build=x86_64-apple-darwin21.4.0 
CXXFLAGS="-I/usr/local/include " CCFLAGS="-I/usr/local/include " 
LDFLAGS="-L/usr/local/lib " CPPFLAGS="-I/usr/local/include " --enable-libatomic
--enable-libgomp --enable-libitm --enable-libquadmath
--enable-libquadmath-support -enable-shared --enable-shared-libgcc
--enable-static --enable-version-specific-runtime-libs
--with-sysroot=/Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk 

Similar for 11.1 and 11.2.
Using XCODE 13 on MacOS 12.3.1

NJOY21 is available at:  https://www.njoy21.io
The error when compiling the ERRORR.F90 subroutine.

NJOY configure script:
cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_VERBOSE_MAKEFILE:BOOL=TRUE -D
CMAKE_CXX_COMPILER=/usr/local/gcc-1120/bin/x86_64-apple-darwin21.4.0-c++ -D
CMAKE_Fortran_COMPILER=/usr/local/gcc-1120/bin/x86_64-apple-darwin21.4.0-gfortran
-D CMAKE_Fortran_FLAGS_RELEASE='-fno-stack-limit -frecursive -fcheck=all
-pedantic -Wdo-subscript  -std=legacy -v -fdump-tree-original -Wdo-subscript '
../


Compiler output:


[ 27%] Building Fortran object
_deps/njoy-build/CMakeFiles/njoy.dir/src/samm.f90.o
/Users/kermitnuc/NJOY21/bin/_deps/njoy-src/src/samm.f90:4518:38:

 4515 |    do n=1,100
      |             2                         
......
 4518 |          a(n)=-(delta*(xn-1)*(xn-2)*a(n-1)+&
      |                                      1
Warning: Array reference at (1) out of bounds (0 < 1) in loop beginning at (2)
[-Wdo-subscript]
/Users/kermitnuc/NJOY21/bin/_deps/njoy-src/src/samm.f90:4519:37:

 4515 |    do n=1,100
      |             2                        
......
 4519 |            (rhoi-2*eta)*(delta**2)*a(n-2)+(delta**3)*a(n-3))/&
      |                                     1
Warning: Array reference at (1) out of bounds (-1 < 1) in loop beginning at (2)
[-Wdo-subscript]
/Users/kermitnuc/NJOY21/bin/_deps/njoy-src/src/samm.f90:4519:55:

 4515 |    do n=1,100
      |             2                                          
......
 4519 |            (rhoi-2*eta)*(delta**2)*a(n-2)+(delta**3)*a(n-3))/&
      |                                                       1
Warning: Array reference at (1) out of bounds (-2 < 1) in loop beginning at (2)
[-Wdo-subscript]
[ 28%] Building Fortran object
_deps/njoy-build/CMakeFiles/njoy.dir/src/errorr.f90.o
f951: internal compiler error: Segmentation fault: 11
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://gcc.gnu.org/bugs/> for instructions.
make[2]: *** [_deps/njoy-build/CMakeFiles/njoy.dir/build.make:239:
_deps/njoy-build/CMakeFiles/njoy.dir/src/errorr.f90.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:2603:
_deps/njoy-build/CMakeFiles/njoy.dir/all] Error 2
make: *** [Makefile:161: all] Error 2

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2022-04-10 15:43 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-06 15:59 [Bug fortran/105182] New: compiling NJOY21 causes a ICE segmentation fault: 11 kermitnuc at gmail dot com
2022-04-06 17:06 ` [Bug fortran/105182] " kargl at gcc dot gnu.org
2022-04-06 20:50 ` kermitnuc at gmail dot com
2022-04-06 20:57 ` sgk at troutmask dot apl.washington.edu
2022-04-06 21:54 ` kermitnuc at gmail dot com
2022-04-06 23:38 ` sgk at troutmask dot apl.washington.edu
2022-04-07  1:09 ` kermitnuc at gmail dot com
2022-04-07  2:58 ` sgk at troutmask dot apl.washington.edu
2022-04-07  4:51 ` kargl at gcc dot gnu.org
2022-04-07  7:08 ` [Bug fortran/105182] [11/12 Regression] " rguenth at gcc dot gnu.org
2022-04-07  7:08 ` rguenth at gcc dot gnu.org
2022-04-07 19:47 ` kargl at gcc dot gnu.org
2022-04-07 21:23 ` kargl at gcc dot gnu.org
2022-04-07 21:35 ` anlauf at gcc dot gnu.org
2022-04-07 21:41 ` kargl at gcc dot gnu.org
2022-04-07 21:58 ` anlauf at gcc dot gnu.org
2022-04-07 22:35 ` sgk at troutmask dot apl.washington.edu
2022-04-08  8:04 ` gscfq@t-online.de
2022-04-08 16:04 ` kargl at gcc dot gnu.org
2022-04-10 15:43 ` kermitnuc at gmail dot com

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).