Actually, it should have been compiled and built on a Mac M1 (arm64). This means that the Ruby interpreter provided by Apple has been compiled and built on a Mac with an Intel CPU (x86_64), although it is meant for a " Target CPU: universal". The output on your Terminal will be OS: darwin2 ![]() Open the Terminal (in the Finder, menu Go > Utilities) and type the following 2 commands to run the code: cd ~/Desktop It prints out some infos about the CPU architecture for which the Ruby interpreter has been built. Create a text file with the following code and store it on your Desktop. An existing code might break for reasons that are hard to discover. During a transition period, they have a tool named Rosetta to execute legacy code in the new CPU architecture.įor the casual user, the magic is seamless but a programmer who works at the bleeding edges may find surprises. ![]() They did it again in 2020, moving from Intel to ARM. Apple did that once in 2007 when they moved from Power PC to Intel. The whole software base has to be recompiled for the new CPU. Even for a computer manufacturer like Apple, switching from a CPU to another is not a simple task.
0 Comments
Leave a Reply. |