[R-SIG-Mac] GCC v. LLVM

Marc Schwartz marc_schwartz at me.com
Sun Mar 13 16:18:58 CET 2011


On Mar 11, 2011, at 9:01 AM, Simon Urbanek wrote:

> On Mar 9, 2011, at 8:26 PM, Anirban Mukherjee wrote:
> 
>> Folks,
>> 
>> I was wondering what the forward plans are for R on Mac vis-a-vis
>> apple-gcc/Clang. Xcode 4 was just released with LLVM 2.x.
> 
> For some definition of "released" - it's not really available to OS X users in general. For all practical purposes it's still a beta.

Simon,

Perhaps I am missing an implicit distinction being made, but XCode 4.0 is generally available to anyone on OSX, albeit there is a distinction from the prior versions.

Up until now, you could sign up for a *free* Apple Developer program account and download XCode. You did not have to pay the $99 U.S. for an annual membership, which also gave you access to the various SDK's required for OSX and iOS. This is how I have been obtaining XCode for the past two years for free, since moving from Fedora. 

The model has now changed with 4.0, where you can either:

1. Pay the $99 U.S. annual fee and download XCode from http://developer.apple.com/xcode/

2. Go to the App Store on OSX and pay $4.99 U.S. to obtain XCode that way from http://itunes.apple.com/us/app/xcode/id422352214?mt=12&ls=1


Clearly, the second option would be the most cost effective for general users, especially if they are not going to be building apps to make them available in the OSX or iOS App Stores. It is no longer free, but to pay $4.99 U.S. for the toolkit is arguably a steal.

What am I missing in your statement above regarding general availability to OSX users?

Also, are there plans afoot to move to XCode 4.0 for OSX builds of R? 

Thanks and regards,

Marc

> 
>> From what I
>> can tell, Apple will in the future only support Clang/LLVM. For now, I
>> believe they are still including the same gcc as with 3.2. But longer
>> term, the move seems to be to Clang/LLVM.
>> 
>> http://developer.apple.com/technologies/tools/whats-new.html
>> http://clang.llvm.org/
>> 
>> Does R build with Clang/LLVM? I know Clang is being developed with a
>> view to ensure GCC "compatibility".
>> 
> 
> As Brian pointed out, R doesn't care. The only annoying part for me as a Mac binary maintainer is that it means Apple has abandoned the only branch that supported Fortran back-end, so in the future we will not be able to provide native Fortran for Xcode. This has been known for a while and Apple's stance is that they don't care about Fortran, so in some (but not immediate) future we may be back to the mess of mixing compilers.
> 
> Note that LLVM and clang don't really have any real benefits for the R users so far. Tests suggest that they make some parts slower and we could not measure any overall benefit (unlike let's say on arm), so people were not rushing to llvm/clang so far. Apple's move to llvm/clang is really based on a political decision, not a technical one. The only benefit I see so far is what Brian mentioned as well that some people will have to realize that gcc is not the standard and can test on other compilers to find their bugs.
> 
> Cheers,
> Simon



More information about the R-SIG-Mac mailing list