• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Xcode seems to be generating bad code
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Xcode seems to be generating bad code


  • Subject: Re: Xcode seems to be generating bad code
  • From: Jeff Laing <email@hidden>
  • Date: Fri, 27 Apr 2012 19:54:58 +1000

Ok, just to give this closure, changing my project to use -O1 instead of -O0 resulted in the application running again.

Thanks to Chris for the speedy response,

Jeff Laing <email@hidden>
-------------------------------------------------------------------------------
"... because even if we can't um, if we can't rise to his level, no at
 least we can, we can drag him down to ours ..."
                                             -- William Gaddis, "JR".


On Fri, Apr 27, 2012 at 8:55 AM, Chris Lattner <email@hidden> wrote:
On Apr 26, 2012, at 3:40 PM, Jeff Laing wrote:

> I'm sorry for the bug, it is already fixed int he Xcode 4.4 developer previews.


Since this is actually tripping over code in an opensource code-base that I'd rather not change, I'd prefer to switch back to GCC (if that fixes the problem) for this project.  However, when I've done that in all the controls I can find, I get an error at 'precompile headers' time telling me that "-fobjc-arc" is not valid.

I assume that this is an LLVM option being passed to GCC but I can't for the life of me see where I turn it off.  The "Automatic Reference Counting" popup is definitely off - what other knobs do I need to push?

This may be complicated up by the fact that I have sub-projects, but I believe I have hit every copy of the appropriate option selectors.  Is it possible this is caused because I have the C dialect specified as "compiler default" and my *system* default compiler is LLVM while my *project* compiler is GCC ?

GCC isn't supported by Xcode anymore.  We do have llvm-gcc still, but it is quite old, not getting updates, and I would *not* recommend switching to it.

If you'd like a workaround that doesn't require a source change, just switch these files to build at -O1 in the debug configuration.  The bug *only* impacts -O0.

-Chris


 _______________________________________________
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

References: 
 >Xcode seems to be generating bad code (From: Jeff Laing <email@hidden>)
 >Re: Xcode seems to be generating bad code (From: Chris Lattner <email@hidden>)
 >Re: Xcode seems to be generating bad code (From: Jeff Laing <email@hidden>)
 >Re: Xcode seems to be generating bad code (From: Chris Lattner <email@hidden>)

  • Prev by Date: Missing iPhone OS SDK?
  • Next by Date: What causes schemes to screw up and not show iOS Device or the Simulator?
  • Previous by thread: Re: Xcode seems to be generating bad code
  • Next by thread: Xcode Cannot Evaluate "Implicit Dependencies"
  • Index(es):
    • Date
    • Thread