https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96711
--- Comment #15 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Harald Anlauf <anl...@gcc.gnu.org>: https://gcc.gnu.org/g:9164caf25cb210ad0a69357b226e39913aff00d1 commit r11-3042-g9164caf25cb210ad0a69357b226e39913aff00d1 Author: Harald Anlauf <anl...@gmx.de> Date: Mon Sep 7 21:41:45 2020 +0200 PR fortran/96711 - ICE with NINT() for integer(16) result When rounding a real to the nearest integer, temporarily convert the real argument to a longer real kind when the result is of type/kind integer(16). gcc/fortran/ChangeLog: * trans-intrinsic.c (build_round_expr): Use temporary with appropriate kind for conversion before rounding to nearest integer when the result precision is 128 bits. gcc/testsuite/ChangeLog: * gfortran.dg/pr96711.f90: New test.