
Apple Rejects iOS App for Using MoltenVK (Vulkan Over Metal) - AlexeyBrin
https://www.phoronix.com/scan.php?page=news_item&px=Apple-Rejects-iOS-MoltenVK&x
======
GeekyBear
Nat Brown from Valve posted a comment on the article:

>I know app rejections and the Apple ecosystem rules can be frustrating and
cause a lot of consternation, but in this case I _think_ this is likely a
legitimate rejection for using the kIOSurfaceIsGlobal=true flag when creating
an IOSurface - Apple documents this as private and not allowed by sandboxed
apps on iOS, and there are legitimate security & sandbox reasons to not
support IOSurfaces that can be guessed and mapped to a foreign process using
IOSurfaceLookup(). It's likely Apple's static analyzer found this during
submission. We (Valve) worked to add this type of IOSurface-backed MTLTexture
for Vulkan VR support for macOS and I suspect it slipped into the iOS build
inadvertently - we don't need that support on iOS (yet? If somebody knows the
developer and can point them my way (natb@valvesoftware.com) I'd be happy to
figure out if this was the only issue, and I'll create a PR for MoltenVK to
drop the global flag out of the iOS build.

>Apple graphics folks I work with are fine with MoltenVK, and many Apple and
AMD folks have provided concrete technical feedback to improve the performance
of MoltenVK, and we have uncovered bugs in HLSL->GLSL->SPIR-V->MSL together
which should help make the entire graphics ecosystem stronger.

[https://www.phoronix.com/forums/forum/phoronix/latest-
phoron...](https://www.phoronix.com/forums/forum/phoronix/latest-phoronix-
articles/1034847-apple-rejects-ios-app-for-using-moltenvk-vulkan-alleged-non-
public-api/page4)

So, no. Apple isn't out to get MoltenVK. On the contrary, they have been
helping improve it's performance.

------
colejohnson66
That’s a deceptive title. It wasn’t the use of MoltenVK, it was that MoltenVK
used non public APIs. It even says in the article:

> We were alerted today by an indie game studio that one of their iOS games is
> now rejected by Apple over its MoltenVK usage. Specifically, the game was
> rejected for "non-public API" usage. Apple's rejection letter cites the use
> of non-public interfaces around IOSurface, which is used directly by
> MoltenVK.

~~~
ashleyn
Seems to me an all-too-convient rationale to force devs to use the proprietary
Metal framework directly.

~~~
AlphaSite
No... Sounds like a commonly enforced policy which is being enforced normally.
Why would they really care about which gfx api they use?

~~~
tmd83
I thought apple in general follow this guideline unless you are one the big
guys? Is that right or am I remembering this wrong?

------
0x0
There's an issue for this on the MoltenVK github page:
[https://github.com/KhronosGroup/MoltenVK/issues/193](https://github.com/KhronosGroup/MoltenVK/issues/193)

~~~
ryandrake
Unfortunately, there's no information there about which private API use needs
to be removed.

~~~
huebnerob
The only level of private API use that Apple will accept is 'none', so this
question is at best immaterial. _All_ of the private API use needs to be
removed.

~~~
ryandrake
Right—they (Molten) might not know which of their API calls is to a private
API. Although that’s doubtful—you have to deliberately go out of your way to
use a private iOS API, using performSelector: or similar.

------
bananaboy
The confusing thing about this situation is that the game apparently was
developed in Unity 3D, which has a Metal backend for iOS, with a fallback to
OpenGL ES for older devices. Unity doesn't have a Vulkan backend for iOS.

------
sneak
from TFA: MoltenVK uses non-public APIs, so this is no policy change from the
app store

------
mastrsushi
Apple's Metal migration is nothing new, stop complaining.

------
shmerl
Typical Apple jerk move.

1\. Apple didn't provide Vulkan support.

2\. Developers of MoltenVK found "public" Metal API to be inadequate, and used
something that Apple considers not public to implement Vulkan translation.

3\. Apple found an excuse to ban usage of MoltenVK under pretense that their
non public APIs shouldn't be used.

Surely, Apple could:

1\. Provide Vulkan to begin with.

2\. Provide public APIs in Metal that are adequate to implement Vulkan.

But doing that would reduce Apple's lock-in, so they are resorting to jerk
moves. Apple being Apple.

~~~
innagadadavida
To play the devils advocate, Why should Vulcan propagate their own APIs
instead of picking one and porting others to work on top of it? All they are
doing is this: [https://xkcd.com/927/](https://xkcd.com/927/) Considering they
don’t control any platform, they are misguided.

~~~
nextweek2
Vulkan was called Mantle before AMD gave it to the open standards group.
Mantle existed before Metal and Apple knew it was being made into an open
standard before they released Metal.

AMD and Khronos were open about their plans and Apple was/is part of the
group.

To answer your question, Khronos are trying to promote an open free API to
help developers save time and effort, picking Metal as a closed source and
late arrival would be unworkable.

