Live data from Hacker News

Translating an ARM iOS App to Intel macOS Using Bitcode

highcaffeinecontent.com

11–20 of 25 posts

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#11
post #6

The intro makes it sound like this could be feasible for translating x86 Mac apps into ARM Mac apps. > So, what if the Mac switched to using ARM chips instead of Intel? Well, as you can see, Apple could use Bitcode to translate every Bitcode-enabled app on the Mac App Store, without consulting developers, so it would be ready to go on day one. But: > Apple doesn't enable Bitcode for submissions to the Mac App Store t…

That's exactly my thinking-- it might be feasible for Apple to use bitcode during an x86 to ARM transition, but what problem is that actually solving? At best, Apple announces mandatory bitcode* for macOS App Store apps at WWDC in 2019; Apple announces the first ARM Macs in 2020 or 2021. So you've got a window of maybe a year or two of apps that don't have to be recompiled to support ARM, and most are likely still be…

Apple, having already forced PPC->X86 and now forcing X86->X64, clearly has no difficulty forcing an architecture update every 5 years, stranding apps in the past if they don’t update. Saying that they wouldn’t force X64->ARM64 due to migration issues they have repeatedly accepted makes no sense, given their history - and especially having done so regardless of Adobe’s inability to keep up.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#12

Earlier quoted context omitted.

That's exactly my thinking-- it might be feasible for Apple to use bitcode during an x86 to ARM transition, but what problem is that actually solving? At best, Apple announces mandatory bitcode* for macOS App Store apps at WWDC in 2019; Apple announces the first ARM Macs in 2020 or 2021. So you've got a window of maybe a year or two of apps that don't have to be recompiled to support ARM, and most are likely still be…

Apple, having already forced PPC->X86 and now forcing X86->X64, clearly has no difficulty forcing an architecture update every 5 years, stranding apps in the past if they don’t update. Saying that they wouldn’t force X64->ARM64 due to migration issues they have repeatedly accepted makes no sense, given their history - and especially having done so regardless of Adobe’s inability to keep up.

They've been even more aggressive than you suggest. They promised 64-bit Carbon in 10.5, and included it in developer seeds, before finally yanking it from the final release. Adobe found out it was cancelled at the same time as everyone else: when Apple announced it at WWDC.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#14
post #12

Earlier quoted context omitted.

Apple, having already forced PPC->X86 and now forcing X86->X64, clearly has no difficulty forcing an architecture update every 5 years, stranding apps in the past if they don’t update. Saying that they wouldn’t force X64->ARM64 due to migration issues they have repeatedly accepted makes no sense, given their history - and especially having done so regardless of Adobe’s inability to keep up.

They've been even more aggressive than you suggest. They promised 64-bit Carbon in 10.5, and included it in developer seeds, before finally yanking it from the final release. Adobe found out it was cancelled at the same time as everyone else: when Apple announced it at WWDC.

My recollection is that Apple did in fact ship a 64-bit HIToolbox library, but they didn't allow the general public to use it. I thought Adobe was one of the few people who were allowed to use it though, as a temporary measure until they rewrote Photoshop to stop using Carbon. I could be wrong though, that was a long time ago.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#15

Earlier quoted context omitted.

That's exactly my thinking-- it might be feasible for Apple to use bitcode during an x86 to ARM transition, but what problem is that actually solving? At best, Apple announces mandatory bitcode* for macOS App Store apps at WWDC in 2019; Apple announces the first ARM Macs in 2020 or 2021. So you've got a window of maybe a year or two of apps that don't have to be recompiled to support ARM, and most are likely still be…

Apple, having already forced PPC->X86 and now forcing X86->X64, clearly has no difficulty forcing an architecture update every 5 years, stranding apps in the past if they don’t update. Saying that they wouldn’t force X64->ARM64 due to migration issues they have repeatedly accepted makes no sense, given their history - and especially having done so regardless of Adobe’s inability to keep up.

Both PPC->x86 and x86->x86_64 had (temporary) migration paths. The x86->x86_64 path was pretty easy; x86 apps were still supported for a rather long time. The PPC->x86 migration path wasn't as clean, but they did ship Rosetta for a couple of years before ditching it.

If they do Intel->ARM they'll need some sort of migration strategy. Would that involve a Rosetta 2.0?

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#16
post #6

The intro makes it sound like this could be feasible for translating x86 Mac apps into ARM Mac apps. > So, what if the Mac switched to using ARM chips instead of Intel? Well, as you can see, Apple could use Bitcode to translate every Bitcode-enabled app on the Mac App Store, without consulting developers, so it would be ready to go on day one. But: > Apple doesn't enable Bitcode for submissions to the Mac App Store t…

Bitcode for the MacOS App Store would make sense if Intel ever gets its head out of its backside and was able to ship the wide variety of processors Apple wants. Then they could be optimized at install time for the exact processor on your Mac.

I’m not sure it’s really worth it today but this support would give Apple air cover for a future intel-arm transition.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#18
post #8
post #6

The intro makes it sound like this could be feasible for translating x86 Mac apps into ARM Mac apps. > So, what if the Mac switched to using ARM chips instead of Intel? Well, as you can see, Apple could use Bitcode to translate every Bitcode-enabled app on the Mac App Store, without consulting developers, so it would be ready to go on day one. But: > Apple doesn't enable Bitcode for submissions to the Mac App Store t…

”ARC appears to use some inline assembly, which means you'll need to disable ARC for a project for arm64-to-x86 translation to succeed right now.” That’s fairly easily fixed, certainly if you’re Apple. They already have the equivalent x86 code (Swift and modern Objective-C couldn't exist without it), so they could detect the specific inline ARM code fragment and replace it by the equivalent inline x86 code.

This seems like it would be very fragile.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#19
I would be very surprised (and impressed!) if Apple managed to pull this off. With the bitcode transition on watchOS Apple had full control over the ABI and architecture that they were going to target: this isn't the case for x86. Sure, this works for the very simple case presented here, but I forsee it quickly breaking down for any non-trivial application. At the very least, it will not work correctly on every application.

Re: Translating an ARM iOS App to Intel macOS Using Bitcode

#20

Earlier quoted context omitted.

That's exactly my thinking-- it might be feasible for Apple to use bitcode during an x86 to ARM transition, but what problem is that actually solving? At best, Apple announces mandatory bitcode* for macOS App Store apps at WWDC in 2019; Apple announces the first ARM Macs in 2020 or 2021. So you've got a window of maybe a year or two of apps that don't have to be recompiled to support ARM, and most are likely still be…

Apple, having already forced PPC->X86 and now forcing X86->X64, clearly has no difficulty forcing an architecture update every 5 years, stranding apps in the past if they don’t update. Saying that they wouldn’t force X64->ARM64 due to migration issues they have repeatedly accepted makes no sense, given their history - and especially having done so regardless of Adobe’s inability to keep up.

The intel transition was 13 years ago? And the powerpc era lasted from 1992ish to 2005?
Post reply on HN