This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/31262] New: -fno-range-check can trigger ICE
- From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Mar 2007 12:24:18 -0000
- Subject: [Bug fortran/31262] New: -fno-range-check can trigger ICE
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
$ cat uu.f90
print *, 7_8*huge(0_8)+17_8
end
$ gfortran -static uu.f90 -fno-range-check
uu.f90: In function ?MAIN__?:
uu.f90:1: internal compiler error: in gfc_conv_mpz_to_tree, at
fortran/trans-const.c:183
There's an assertion in gfc_conv_mpz_to_tree:
/* We assume that all numbers are in range for its type, and that
we never create a type larger than 2*HWI, which is the largest
that the middle-end can handle. */
It's wrong. Now that we have -fno-range-check, we should handle this in some
way, probably by a modulo operation.
--
Summary: -fno-range-check can trigger ICE
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: fxcoudert at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31262