Could someone please explain to me...

Discussion in 'Buying Tips and Advice' started by levitynyc, Oct 19, 2006.

  1. levitynyc macrumors 65816

    Joined:
    Aug 19, 2006
    #1
    What does it mean when people talk about something running "Native" or "Universal Binary" with "Rosetta emulator" with something like Photoshop?

    I hear people talking about it on here all the time, but I don't know what it means.

    Could someone explain this is semi laymen terms?

    Thanks
     
  2. MacBoobsPro macrumors 603

    MacBoobsPro

    Joined:
    Jan 10, 2006
    #2
    Its all to do with the switch from PPC to Intel processors. For OSX apps to run correctly on Intel they need to be re-written. These re-written apps are called Universal Binaries. They can run natively (without being emulated) on both PPC and Intel CPUs.

    Current apps written specifically for PPC can run on Intel CPUs but they have to be 'emulated' by Rosetta. This emulation takes a lot of CPU grunt and as such PPC apps run slow on Intel machines.

    Photoshop CS2 is still only a PPC app but will be updated to a UB in CS3. So it will absolutely scream on a MacPro.

    Hope this helps. :)
     
  3. kretzy macrumors 604

    kretzy

    Joined:
    Sep 11, 2004
    Location:
    Canberra, Australia
    #3
    Apple recently changed the processors they use. Older Macs used PPC processors and the new ones use Intel processors. Software designed for the PPC Macs does not run on Intel Macs (hence, it's not native).

    Rosetta allows the PPC software to be used on Intel Macs through emulation (it kind of makes it pretend that it's a PPC Mac).

    Universal Binary means that the program has been converted to run on both PPC and Intel Macs natively, without any emulation.

    Hope that helps. :)

    Edit: gah! too slow. :eek:
     
  4. atszyman macrumors 68020

    atszyman

    Joined:
    Sep 16, 2003
    Location:
    The Dallas 'burbs
    #4
    I'll take a stab at this.

    When Apple switched to Intel processors the instruction set that the computer understands also switched. This means that they effectively broke every application ever made for OSX. The solution was to include Rosetta which translated the instruction set for the GX processors to instructions understood by the Intel processors. This translation, while fast, still takes up CPU cycles and thus slows down applications. The better solution is to rebuild the applications to run natively which means they are built to use the instruction set that Intel understands directly rather than have to be translated. Since it would take some time for Intel Macs to reach full market penetration Apple came up with the concept of Universal Binaries which effectively speak to both the GX processors and the Intel processors in their native language.

    Think of it like this if you still don't understand.

    OSX previously spoke Swedish when using the GX processors. By switching to Intel now OSX speaks Chinese. So they decided to send a translator who can translate from Swedish to Chinese (Rosetta). Of course this is time consuming since everything said has to be translated. It is easier if everything just spoke Chinese (Native). But since a lot of existing Macs still speak Swedish the best solution is to have a bilingual one that speaks Swedish or Chinese depending on the processor (Universal Binary).

    Hopefully that is as clear as mud....
     
  5. dpaanlka macrumors 601

    dpaanlka

    Joined:
    Nov 16, 2004
    Location:
    Illinois
    #5
    Since 1996 all Macs have had PowerPC processors made by IBM or Motorola, not processors made by Intel or AMD.

    The Motorola and IBM processors are compatible, just as the Intel and AMD processors are compatible. However the two groups are not compatible with each other.

    So when Apple switched from IBM/Motorola (PowerPC) to Intel (Core Duo), software (Rosetta) was written that would translate the older PowerPC into the new Intel language in real time, as you were running the software. This results in a performance hit, as the Intel processors have to not only run your software, but they have to translate it too.

    Which processor the program is written for is it's native processor.

    So PowerPC-native apps run "under Rosetta" - you do not actually launch Rosetta or configure anything, it is completely transparent to you. But these PowerPC-native apps (Microsoft Office for example) will not run as fast as they would if they were native to Intel.

    Universal Binaries are programs which are native to both PowerPC and Intel.
     
  6. Swarmlord macrumors 6502a

    Swarmlord

    Joined:
    Sep 18, 2006
    #6
    Just out of curiosity, does the option to compile a universal binary that will run on both PPC and Intel exist in XCode or is there another extensive document that I need to download and read on inserting compiler directives required? In other words does every program that you develop using the current version of XCode on an Intel Mac automatically qualify as a universal binary or is it compiled to run natively to Intel and not run at all on an older PPC?
     
  7. Erendiox macrumors 6502a

    Erendiox

    Joined:
    Oct 15, 2004
    Location:
    Brooklyn NY
    #7
    When Apple switched it's processors from PowerPC to Intel, they had to make a huge code overhaul on their operating system and all their software. Initially, everything ran on PPC code for the IBM processors G3,G4,G5 etc. Now everything must run in x86 code for the new Intel chips. When you hear everyone talking about universal binaries, a universal binary is software that is designed to run natively in either a PPC or x86 environment. When I say natively, I mean that it runs "naturally" or "without emulation". Emulation is "faking it" in a sense. You're basically making the computer do a whole lot more work to run a program of the other code base. Rosetta is a PPC emulator for Intel. It will run most PPC programs at roughly 50-70% speed in comparison to the "native" speeds of programs written in x86. Right now, everyone is waiting for the universal binary of the Adobe Creative Suite. Since it's still a PPC program, everyone with the new Intel chips has to run it in rosetta and take that emulation slowdown. Once the UB is out, Photoshop will fly.

    Edit: Wow, i'm slow :)
     
  8. MacBoobsPro macrumors 603

    MacBoobsPro

    Joined:
    Jan 10, 2006
    #8
    Isnt it a tick box in Xcode to compile as UB? I recall seeing that when the switch was announced. Im not a developer and have never used Xcode, i may be wrong :p
     
  9. DXoverDY macrumors 6502a

    Joined:
    Apr 19, 2005
    #9
    It's not really a checkbox, it's more of a list. It defaults to PPC (maybe your platform... being on a PPC it defaulted to that for me). You then just add x86 to the list and it will compile a universal binary.

    There was one fault in the first response. Apps don't have to be "rewritten" if they're in Cocoa usually. Maybe minor changes, but most can just be "recompiled" for the new platform. Carbon and others may be a bit different, especially if it has assembly in the project.

    But most Cocoa apps are very easily recompilable. Most got the answers to the other questions in there.
     
  10. MacBoobsPro macrumors 603

    MacBoobsPro

    Joined:
    Jan 10, 2006
    #10
    He did say Laymans terms :p
     
  11. DXoverDY macrumors 6502a

    Joined:
    Apr 19, 2005
    #11
    Then the word "repackaged" would be more his style. "rewritten" makes it sound like a lot more work than it is.
     
  12. Swarmlord macrumors 6502a

    Swarmlord

    Joined:
    Sep 18, 2006
    #12
    Thanks! You answered the next question I had on my mind which was whether XCode allowed the compilation for either platform even on the older processor based Macs.
     
  13. gauchogolfer macrumors 603

    gauchogolfer

    Joined:
    Jan 28, 2005
    Location:
    American Riviera
    #13
    Good explanation, atszyman, I think it gets the point across great.
     
  14. levitynyc thread starter macrumors 65816

    Joined:
    Aug 19, 2006
    #14
    Perfect!

    Thanks!
     
  15. dpaanlka macrumors 601

    dpaanlka

    Joined:
    Nov 16, 2004
    Location:
    Illinois
    #15
    A little bit of interesting historical background...

    The same situation took place 12 years ago. Originally, Macs used 68000-based "68k family" processors. They were neither PowerPC, nor Intel, but a third processor type, this time only from Motorola.

    When Apple switched from 68k to PowerPC, all the old 68k-native stuff had to be run under emulation (real time translation) on the newer PowerPC machines, but at less-than-native speeds. PowerPC native apps slowly appeared, but to maintain compatibility with all the 68k machines that were around at that time, most apps were released as "FAT" for a few years, meaning they were 68k and PowerPC native, or 68k with at least some PowerPC optimizations.

    Unlike this Intel switch, where Apple's entire line was switched from PowerPC in a time period spanning January - August of a single year, the PowerPC transition took years. The first PowerPC Macs appeared in January 1994. The last 68k Mac to be discontinued was the PowerBook 190cs, which lasted until September 1996.

    That's over two and a half years to complete the transition, and the last 68k machine was dropped only a year and two months before the first G3 appeared!
     

Share This Page