This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Need advice on bounds checking approaches
- To: Geoff Keating <geoffk at cygnus dot com>
- Subject: Re: Need advice on bounds checking approaches
- From: Greg McGary <gkm at eng dot ascend dot com>
- Date: 28 Mar 2000 13:25:51 -0700
- Cc: law at cygnus dot com, gcc at gcc dot gnu dot org
- References: <679.954265252@upchuck> <200003281930.LAA01001@localhost.cygnus.com>
Geoff Keating <geoffk@cygnus.com> writes:
> They shouldn't end a basic block. So long as the compiler knows that
> 'trap' RTXs are memory barriers, I think it can optimise them just
> like any other insn; and I think that's what it now does.
Please expand on this. I'm not sure what you mean here. My only
knowledge of barriers is what's in the gcc manual, namely that they
mark places where control cannot flow past. However, this is not the
case with bounds checks. Most often, control flows past the checks
because the trap condition is false. Even when the trap condition is
true, the OS should have the option of logging the failure then
resuming execution rather than simply terminating.
Greg