Create AOT Checklist for IOS (ExecutionEngineException)

First of all, I posted a similar question on answer.unity.com and realized that it affects the wider community ... so please do not take this as a cross-over.

Deploying C # code for iOS has recently become a nightmare for me. It all started with an ExecutionEngineException exception when I tried to deploy my game to the iPad and I used a proven build on a mature well.

In the past few days, I have done my homework and discovered dozens of questions related to ExecutionEngineException. Since I find out that there is no magic solution, only to bypass specific code.

Now here is the problem: suppose you have verified module code. (for example, an AI game or something that is not directly related to the iOS platform). When working on iOS, this will turn into a minefield. You cannot know, and unit test, what part of the code will break.

It destroys all my (our?) Ideas about quality and software testing ...

We must find a solution here. Ideally, we should run AOT-ed code on the desktop against unit test. I think this is not possible at the moment, please correct me if I am mistaken and share the steps of how to do it (preferably on Windows?)

As a backup plan, we must create a detailed list of which code constructors should not be used if targeting an AOT-ed platform, such as iOS

My experience:

1) Using FirstOrDefault with type values ​​2) Using Sum (customType = (gt) customType.Property)

Does anyone know how to deal with this?

Hello

+4
source share
1 answer

Suppose you have a verified device code.

If you already have unit tests, you're in luck. You just need to configure those unit tests on your iOS device using Touch.Unit .

As a backup plan, we must create a detailed list of which code constructors should not be used if targeting an AOT-ed platform, such as iOS

Closest you will find MonoTouch limitation . Context, rather than an API, is often the most important detail.

eg. generics using value-type will cause problems (since it's hard to find what needs to be generated). People often encounter this when using LINQ, but this is not a LINQ problem, but the types used in LINQ queries.

1) Using FirstOrDefault with type values

AFAIK, which has been fixed in MonoTouch for some time (at least a few of its variants). The Unity OTOH engine may not yet have these fixes.

2) Using Sum (customType = (gt) customType.Property)

This is the case when ignorance of the type (s) does not allow us to say whether it works or not. If / when you receive such cases, report bugzilla about them, because we can include them in our test suite (for future releases) and often can provide a quick workaround in most cases.

+4
source

Source: https://habr.com/ru/post/1437151/


All Articles