Search code examples
cswiftarmintelapple-silicon

What problems are to be expected for Swift and C developers when developing applications for Apple Silicon (ARM) processors?


After the announcement by Apple in the future to rely on ARM processors and the output of test devices with such processors. Does the question arise which difficulties are to be expected? Swift is a high level language and the compiler should in my opinion be able to translate for ARM 64 bit processors, so that current source code could be compiled for ARM.

I ask for food for thought and clarification. Thank you very much.


Solution

  • This answer will focus on C, as I don't have any experience with Swift. If you write a normal application (no cross platform library), only using platform independent libraries (Those will handle this for you)+libc, you won't have any problem.

    But if you use (inline-)assembly or intrinsics (like __builtin_ia32_pminsb256), you would have to either translate it to ARM or write it new (==>To support x86, too).

    Furthermore x86 devices with MacOS will stay around some years, so you have either have to support two architectures for a few years or simply drop support for x86.