Hacker News new | ask | show | jobs
by MR4D 3428 days ago
This has been rumored for some time. I believe it's true, but then again, Apple kills off most projects before they see the light of day. Whether this ever makes it to consumers is the important question.

That being said, I've seen a number of comments about running iOS apps on Macs, or "convertible" Macs/iPads, and so on. I think those are off base given the supposed purity that Apple always talks about.

However, there is one thing I've never seen mentioned - a combined Mac/iOS binary. Similar to the old Universal binary for PPC/Intel, this could be a single app that just has different UX depending on the device it's run on.

I'm not sure why nobody has talked about that option, as it seems most likely to me, and gives more weight to the ARM everywhere strategy.

One "app", and it would be native, with native UI on whichever device it's running on (Mac/iOS/TV/Watch/etc.). Given Apple's investment into a streamlined complier that they rolled out with Watch, many if not most of the pieces are already in place for this.

It would not surprise me if that is the big announcement for this summer (or next at the latest).

3 comments

I feel like they've been doing this to osX, starting with 10.9 it seems like a lot of the visual flair of iOS has filtered into the macOS environment.

I fear that this will dumb it down too much for the power users, and conversely over-complicate it for the average iOS user. I'd love to be wrong...

Yes, but this is not specifically what I'm talking about.

Think of something like MS Outlook - it's a big, complex app with lots of features. Now imagine that you only write the app once, but design two interfaces for it - one set for the Mac, and the other for the iPad. You compile through XCode, and upload to the App store. Apple notes that their are interfaces for both iPad and Mac, and posts it in both app stores.

Obviously the mechanics would not be exactly like this (I presume a manifest of some kind), but it should be pretty close.

For Apple, this would bring more developers onto their tooling (yes, even many of those that complain about XCode), and allow more developers to target multiple platforms with little extra effort.

In fact, one of the more interesting things is that Apple could even create new platforms that just require some interface additions and an updated manifest.

Have a bug in your code? One fix. One upload. One code review.

One basic problem - macOS has many, many more features than iOS.

There would be a lot more involved than redesigning the UI. The two platforms have fundamentally different class trees all the way from the view and user event classes down to core OS hooks.

There's some limited overlap, but not as much as you might expect.

Merging the two platforms and creating a UI-level split wouldn't be impossible, but it would be a huge job and would effectively mean a rewrite of both OSs - and probably of WatchOS and TvOS too.

It's not obvious this would be a good thing to do. MS tried it, and that was pretty much a disaster.

> MS tried it, and that was pretty much a disaster.

Do you mean the Windows Runtime subsystem? How is it a disaster?

> However, there is one thing I've never seen mentioned - a combined Mac/iOS binary.

Because they're already doing something better. All iOS apps compile to Bitcode, an intermediary representation that can then compile an optimized binary for the target device architecture.[1]

So if there ever were a desire to run iOS apps on Mac, they'd just compile from Bitcode. Having said that, there's explicitly zero desire to do this.

[1] https://developer.apple.com/library/content/documentation/ID...

Bitcode allows you to optimize between chip versions with different opcodes, but not different architectures, word sizes, or endianness.

Source: the recent Accidental Tech Podcast that interviewed Chris Lattner.

Ok fine, but the broader App Thinning featureset of the App Store still means they wouldn't do a universal binary. They'd deliver just what the target device needs.
True, but AArch64 vs AMD64 are not so different (64 bits, little endian, probably quite similar ABIs), it is not unthinkable that the same bitcode could target both architectures.
iOS apps already run on intel via the simulator. There's no need to have a dual binary.