IBM xlc is out

Posted:
in Mac Software edited January 2014
Linkage



It's got a price tag, although no price is given in that document. Objective-C support is included as a "technical preview," so a fully supported implementation is in the works. Supports C89 and C99 standards for C, and the 1998 standard for C++. Compatible with gcc 3.3 and Xcode.



Good stuff.

Comments

  • Reply 1 of 17
    bigbluebigblue Posts: 341member
    So does this mean better/faster compilers for the G5 (and maybe a bit for the G3/G4) ? And will this give us faster and more stable apps ?

    Or do we just get them faster



    Is this the first compiler from IBM for OSX ? Are they better than Apple's or Metrowerks' ?
  • Reply 2 of 17
    deestardeestar Posts: 105member
    Would apple ever use it as there default compiler for say 10.4? Or would this stop support for the G3 processor?
  • Reply 3 of 17
    amorphamorph Posts: 7,112member
    xlc is a better compiler for the G5, and somewhat better at optimizing for PowerPCs in general. It can also target the G4 and the G3, although it's not as well optimized for those. It can be used alongside gcc in the same application, so you can pick whichever works better (use gcc for everything except for files that are only used when running on a G5, for example).



    Right now, it doesn't support Objective-C, so its use in applications will be somewhat limited. Apple will be able to use it to speed up much of OS X, however, since much of its system-level code is written in C and C++. It has built-in support for multiprocessing, auto-threading, and auto-vectorizing (figuring out how to use AltiVec on its own).



    This is IBM's first compiler for Mac OS X, although IBM compiler engineers have contributed to gcc (and continue to). The odds that Apple will ship it as a default compiler are slim, because it's pricey, but the odds that they'll use it in-house to compile all or some of Mac OS X and various iApps are much higher.
  • Reply 4 of 17
    kickahakickaha Posts: 8,760member
    Agreed. I expect that this will be used by Apple for the OS (whoohoo!) and, possibly, as a professional add-on to the Dev Tools, for those shops that want/need it.



    Think of gcc as the 'iCompiler' and xlc as the 'PowerCompiler'.
  • Reply 5 of 17
    deestardeestar Posts: 105member
    Quote:

    Originally posted by Amorph

    xlc is a better compiler for the G5, and somewhat better at optimizing for PowerPCs in general. It can also target the G4 and the G3, although it's not as well optimized for those. It can be used alongside gcc in the same application, so you can pick whichever works better (use gcc for everything except for files that are only used when running on a G5, for example).



    Right now, it doesn't support Objective-C, so its use in applications will be somewhat limited. Apple will be able to use it to speed up much of OS X, however, since much of its system-level code is written in C and C++. It has built-in support for multiprocessing, auto-threading, and auto-vectorizing (figuring out how to use AltiVec on its own).



    This is IBM's first compiler for Mac OS X, although IBM compiler engineers have contributed to gcc (and continue to). The odds that Apple will ship it as a default compiler are slim, because it's pricey, but the odds that they'll use it in-house to compile all or some of Mac OS X and various iApps are much higher.




    Thanks for the insight, hopefully they will implement full Objective-C support pretty soon. As you said in your original post there previewing it at the moment so fingers crossed.



    Quote:

    Technical preview ? Selected functions



    The following selected functions are offered in this initial release of XL C/C++ Advanced Edition V6.0 for Mac OS X, as a "technical preview." Technical Previews provide insight into IBM plans and directions and information and functions are provided "as-is" and without warranty or condition of any kind. Availability of the selected functions will be announced at a later date.



    Objective-C

    XL C/C++ Advanced Edition compiler supports Objective-C.



    Objective-C is an object-oriented programming language based on standard C and is popular in the Mac OS X programming environment. The Objective-C programming is a basis for writing to Cocoa frameworks.



    Would be nice to get a speed increase across the board.
  • Reply 6 of 17
    bartobarto Posts: 2,246member
    Quote:

    Originally posted by Amorph

    The odds that Apple will ship it as a default compiler are slim, because it's pricey, but the odds that they'll use it in-house to compile all or some of Mac OS X and various iApps are much higher.



    With Apple and IBM all chummy, maybe Apple can get a good deal for shipping this as the default compiler? Maybe Apple contributed to this Mac OS X edition, at least with XCode intergration. Apple isn't adverse to paying small per-copy license fees if they have too (for MPEG2, MP3 & MPEG4)...



    Barto
  • Reply 7 of 17
    amorphamorph Posts: 7,112member
    I could easily see Apple working out a deal to bundle xlc and xlf with OS X Server, because the people clustering Xserves will swear eternal fealty to Apple if they do (all right, they'll just be very happy - especially the Fortran programmers). Apple could probably get a good price in return for selling more licenses than IBM ever would otherwise.



    I see OS X continuing to ship with gcc, because it's free, it's ubiquitous (especially in the open source world) and it's actually a nice, powerful complete compiler suite - it just has a few performance issues that Apple and IBM have been knocking down over the past few years.
  • Reply 8 of 17
    telomartelomar Posts: 1,804member
    Quote:

    Originally posted by Barto

    With Apple and IBM all chummy, maybe Apple can get a good deal for shipping this as the default compiler? Maybe Apple contributed to this Mac OS X edition, at least with XCode intergration. Apple isn't adverse to paying small per-copy license fees if they have too (for MPEG2, MP3 & MPEG4)...



    Barto




    Given last I saw the cost of xlc/xlf was in the thousands of dollars I wouldn't be counting on Apple shipping it.
  • Reply 9 of 17
    bigbluebigblue Posts: 341member
    But where does it leave Metrowerks in this story ?
  • Reply 10 of 17
    amorphamorph Posts: 7,112member
    Apparently xlc and xlf for OS X are both $499 per seat. [edit: That's the price of each, so if you want both you're out about $1K.]



    Metrowerks CodeWarrior isn't going anywhere. It has mature cross-platform capabilities and the ability to target a dizzying number of platforms. They've been improving it at a pretty good clip, too.
  • Reply 11 of 17
    kickahakickaha Posts: 8,760member
    OTOH, at .5k$ retail, Apple may just get the nod from IBM to incorporate this into Xcode Pro (speculation, not a hint or rumor) for a price competitive with CodeWarrior et al.



    .5k$/seat is chump change for a big production house with performance anxiety.
  • Reply 12 of 17
    onlookeronlooker Posts: 5,252member
    Quote:

    Originally posted by BigBlue

    So does this mean better/faster compilers for the G5 (and maybe a bit for the G3/G4) ? And will this give us faster and more stable apps ?

    Or do we just get them faster







    I think it's G5 only. You can compile on a G4, or G5, but I think it's solely for 970 G5.
  • Reply 13 of 17
    amorphamorph Posts: 7,112member
    xlc and xlf can target any PowerPC. The optimizations are only for G5, and there are flags you can set that will generate code that only runs on a G5 (for example, enabling the use of the 970's hardware square root instruction), but you can use xlc to compile code that targets a G3 or G4 as well. It's just that the advantage over gcc is less clear.
  • Reply 14 of 17
    Keep in mind that IBM is pouring considerable work into GCC as well.



    Apparently IBM is pushing linux or something?
  • Reply 15 of 17
    Quote:

    Originally posted by Amorph

    xlc and xlf can target any PowerPC. The optimizations are only for G5, and there are flags you can set that will generate code that only runs on a G5 (for example, enabling the use of the 970's hardware square root instruction), but you can use xlc to compile code that targets a G3 or G4 as well. It's just that the advantage over gcc is less clear.



    For my numerically intensive code on a G4, I see anywhere from 3-60% improvement using the Beta version of XL Fortran optimizations depending on the task. So, its optimizer is much better than g77's even on a G4 (I think it is better at unrolling loops, etc. as that is where I get some of the biggest gain).



    When I do it on the G5, well, let's just say I hate going back to my Powerbook.
  • Reply 16 of 17
    Quote:

    Originally posted by 1337_5L4Xx0R

    Keep in mind that IBM is pouring considerable work into GCC as well.



    Apparently IBM is pushing linux or something?




    Keep in mind IBM sells the XL series of compilers for Linux also.
  • Reply 17 of 17
    amorphamorph Posts: 7,112member
    Quote:

    Originally posted by atomicham

    For my numerically intensive code on a G4, I see anywhere from 3-60% improvement using the Beta version of XL Fortran optimizations depending on the task. So, its optimizer is much better than g77's even on a G4 (I think it is better at unrolling loops, etc. as that is where I get some of the biggest gain).



    When I do it on the G5, well, let's just say I hate going back to my Powerbook.




    I was talking about the C compiler's performance. XLF destroys g77 and Alsoft, completely.



    It turns out that XLF for OS X is also more expensive than XLC, $999 vs. $599. Still, that's an easy K to drop for scorching performance in Fortran code.
Sign In or Register to comment.