• 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 5.1 compiler option -Ofast
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Xcode 5.1 compiler option -Ofast


  • Subject: Re: Xcode 5.1 compiler option -Ofast
  • From: Fritz Anderson <email@hidden>
  • Date: Mon, 17 Mar 2014 14:06:13 -0500

On 14 Mar 2014, at 1:41 PM, Alex Zavatone <email@hidden> wrote:

> Just noticed the new compiler option in Xcode 5.1 called Fastest, Aggressive Optimization.
>
> I didn't see any info on this in the What's New in Xcode docs.  Is there any handy reference for this new feature?
>
> Thanks.

Answering the actual question? I’ve heard of that.

You might learn something from groveling the clang source code; it’s open.

However, Apple defaults release builds to -Os (size) for a reason. “Fast” optimizations entail inlining functions that aren’t even declared inline, and unwinding loops into serial repetitions of the loop content. Tricks like that inflate the binary, and make overflows of the processor cache more likely and more frequent. Cache memory can keep up with the CPU; RAM can’t. Faulting the cache costs you more speed than “efficient” code.

Local (single-file) use of aggressive optimization might pay off for small inner loops, but -Os is where you should start.

	— F



 _______________________________________________
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


  • Follow-Ups:
    • Re: Xcode 5.1 compiler option -Ofast
      • From: Jens Alfke <email@hidden>
References: 
 >Xcode 5.1 compiler option -Ofast (From: Alex Zavatone <email@hidden>)

  • Prev by Date: Re: Xcode 5.1 is again modifying storyboards upon opening them?
  • Next by Date: Re: Xcode 5.1 is again modifying storyboards upon opening them?
  • Previous by thread: Xcode 5.1 compiler option -Ofast
  • Next by thread: Re: Xcode 5.1 compiler option -Ofast
  • Index(es):
    • Date
    • Thread