Re: C local auto-initialized?
Re: C local auto-initialized?
- Subject: Re: C local auto-initialized?
- From: Chris Suter <email@hidden>
- Date: Fri, 21 Sep 2007 09:11:52 +1000
On 21/09/2007, at 8:31 AM, Fritz Anderson wrote:
On Sep 20, 2007, at 5:14 PM, Greg Guerin wrote:
Jack Repenning wrote:
.... the Release disassembly might even show your uninitialized
variables
have been optimized entirely into registers, with no in-memory
presence at
all.
And possibly another bug to look for: garbage *register* values.
Remember my purpose — to teach by demonstrating a non-pristine value.
I don't object to a non-pristine value. I _want_ it.
And it's there; hurray! It loads into register $f0; hurray!
But the value disappears at the instant something is added to the
register containing it. Why?
What exactly is the garbage value? If the exponent is large and
negative you'll get the behaviour you're seeing.
Note that if you compile with all warnings enabled (which I do as a
matter of course) and you have optimisations enabled, the compiler
will warn you that you're using an uninitialised variable.
- Chris
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden