https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100283
Bug ID: 100283 Summary: Call to MIN0 with integer(8) arguments raises an ICE Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: bardeau at iram dot fr Target Milestone: --- Calling the legacy MIN0 function with integer(8) arguments is probably not in the F77 standard, might be a GNU extension. It used to be accepted with gfortran 10 and older. ~/tmp> cat gfortran11.f90 subroutine smo002() integer(kind=8) :: i,j,k i = min0(j,k) end subroutine smo002 ~/tmp> gfortran -c gfortran11.f90 during RTL pass: expand gfortran11.f90:3:15: 3 | i = min0(j,k) | ^ internal compiler error: in expand_fix, at optabs.c:5532 0x5f3805 expand_fix(rtx_def*, rtx_def*, int) ../../srcdir/gcc/optabs.c:5532 0x8f78bf expand_expr_real_2(separate_ops*, rtx_def*, machine_mode, expand_modifier) ../../srcdir/gcc/expr.c:9304 0x7f8fc5 expand_gimple_stmt_1 ../../srcdir/gcc/cfgexpand.c:3947 0x7f8fc5 expand_gimple_stmt ../../srcdir/gcc/cfgexpand.c:4008 0x7ff03a expand_gimple_basic_block ../../srcdir/gcc/cfgexpand.c:6045 0x7ff03a execute ../../srcdir/gcc/cfgexpand.c:6729 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <https://gcc.gnu.org/bugs/> for instructions. ~/tmp> gfortran -v Using built-in specs. COLLECT_GCC=gfortran COLLECT_LTO_WRAPPER=/home/bardeau/Softs/gcc-11.0.1/bin/../libexec/gcc/x86_64-pc-linux-gnu/11.0.1/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: ../srcdir/configure --with-gmp=/home/bardeau/Softs/gcc-deps --prefix=/home/bardeau/Softs/gcc-11.0.1 --enable-languages=c,c++,fortran --disable-multilib Thread model: posix Supported LTO compression algorithms: zlib gcc version 11.0.1 20210426 (prerelease) (GCC)