gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GNUstep Code Freeze


From: David Chisnall
Subject: Re: GNUstep Code Freeze
Date: Wed, 1 Feb 2012 11:40:03 +0000

On 1 Feb 2012, at 09:10, Fred Kiefer wrote:

> Looks like you found the cause of the problem. We are asking a nil view for 
> its frame. I am used to this case crashing on Sparc processors, it is new to 
> me that gcc 4.6 now also manages to corrupt the stack on i386 when it has to 
> return a structure from a nil call. Somebody will have to write a bug report 
> and a test case for gcc here.

I fixed this in clang about a year ago.  If you send a structure-returning 
message to an object, it inserts a nil check in the caller, so from the 
perspective of the programmer it will always return {0}.

There's a slight performance penalty for doing it, but generally I consider 
slightly slow code to be better than code that corrupts the stack.

David

-- Sent from my Difference Engine



reply via email to

[Prev in Thread] Current Thread [Next in Thread]