From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg McGary To: Alan Lehotsky Cc: geoffk@cygnus.com, law@cygnus.com, gcc@gcc.gnu.org Subject: Re: Need advice on bounds checking approaches Date: Tue, 28 Mar 2000 14:25:00 -0000 Message-id: References: <200003282136.QAA04388@sunspot.tiac.net> X-SW-Source: 2000-03/msg00746.html Alan Lehotsky writes: > One advantage of checking before stomping is that if stomping > memory destroys your stack, it is darn hard to debug the problem... Excellent point. I think the thing to do is implement both alternatives, benchmark and see if there's any compelling reason to relax barrier semantics. If the performance difference is negligible, then always use barrier semantics. If the performance difference is significant, then make it optional. Some might wish to pay the runtime penalty for a guarantee that bounds violations won't stomp the stack.