This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran 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]

Re: [gfortran, patch] fix runtime out-of-bounds checking


ping

Today, as part of my bounds-checking series, here is a patch that
fixes runtime bounds-checking. Currently, the front-end generates
errors for valid code (for example, for zero-sized sections), which
this patch corrects. I also added a check for zero-stride, and checks
for the last element of sections. I also fixed the text of the
messages, from "bounds mismatch" to "Array reference out of bounds".

In fact, this patch generates code for the same checks than my
previous patch for compile-time checks did.

Bootstrapped and regtested on i686-linux, tested that it didn't
introduce regressions for the testcase run with -fbounds-check. I also
manually checked that runtime errors are obtained on all the erroneous
statements of my compile-time testcase
(http://gcc.gnu.org/ml/fortran/2006-06/msg00071.html).

OK for mainline and 4.1?


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