Flutter App Crash on new Xcode 14.0 and iOS 16

This issue has been created since 2022-09-22.

Hi friends,

Before I used Xcode 13.4.1 no problems, after upgrade to xCode 14.0, my app crashes after build, I don't know why :( I get these errors:

UnityFramework`::InitializeMemory():
    0x10ce33f08 <+0>:   stp    x20, x19, [sp, #-0x20]!
    0x10ce33f0c <+4>:   stp    x29, x30, [sp, #0x10]
    0x10ce33f10 <+8>:   add    x29, sp, #0x10
    0x10ce33f14 <+12>:  adrp   x8, 7435
    0x10ce33f18 <+16>:  add    x8, x8, #0xa28            ; guard variable for MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33f1c <+20>:  ldarb  w8, [x8]
    0x10ce33f20 <+24>:  tbz    w8, #0x0, 0x10ce33f88     ; <+128> at MemoryManager.cpp:528:5
    0x10ce33f24 <+28>:  adrp   x0, 7435
    0x10ce33f28 <+32>:  add    x0, x0, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33f2c <+36>:  bl     0x10d3f14c4               ; ::Lock() at Mutex.cpp:61:5
    0x10ce33f30 <+40>:  adrp   x19, 7589
    0x10ce33f34 <+44>:  ldr    x8, [x19, #0xa40]
    0x10ce33f38 <+48>:  cbnz   x8, 0x10ce33f70           ; <+104> [inlined] ~AutoLock at Mutex.h:34:31
    0x10ce33f3c <+52>:  adrp   x8, 7324
    0x10ce33f40 <+56>:  ldr    x0, [x8, #0xb18]
    0x10ce33f44 <+60>:  mov    w9, #0x8330
    0x10ce33f48 <+64>:  movk   w9, #0x4, lsl #16
    0x10ce33f4c <+68>:  add    x9, x0, x9
    0x10ce33f50 <+72>:  str    x9, [x8, #0xb18]
    0x10ce33f54 <+76>:  adrp   x8, 7435
    0x10ce33f58 <+80>:  add    x8, x8, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33f5c <+84>:  cmp    x9, x8
    0x10ce33f60 <+88>:  b.hi   0x10ce33ffc               ; <+244> [inlined] ~AutoLock + 20 at Mutex.h
    0x10ce33f64 <+92>:  bl     0x10ce34c4c               ; ::MemoryManager() at MemoryManager.cpp:834
    0x10ce33f68 <+96>:  str    x0, [x19, #0xa40]
    0x10ce33f6c <+100>: bl     0x10ce34008               ; ::InitializeFallback() at MemoryManager.cpp:892
    0x10ce33f70 <+104>: adrp   x0, 7435
    0x10ce33f74 <+108>: add    x0, x0, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33f78 <+112>: bl     0x10d3f14cc               ; ::Unlock() at Mutex.cpp:68:5
    0x10ce33f7c <+116>: ldp    x29, x30, [sp, #0x10]
    0x10ce33f80 <+120>: ldp    x20, x19, [sp], #0x20
    0x10ce33f84 <+124>: ret    
    0x10ce33f88 <+128>: adrp   x0, 7435
    0x10ce33f8c <+132>: add    x0, x0, #0xa28            ; guard variable for MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33f90 <+136>: bl     0x10e5c48f0               ; symbol stub for: __cxa_guard_acquire
    0x10ce33f94 <+140>: cbz    w0, 0x10ce33f24           ; <+28> [inlined] AutoLock at Mutex.h:33:59
    0x10ce33f98 <+144>: adrp   x0, 7435
    0x10ce33f9c <+148>: add    x0, x0, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33fa0 <+152>: bl     0x10d3f1474               ; ::Mutex() at Mutex.cpp:46
    0x10ce33fa4 <+156>: adrp   x0, 1470
    0x10ce33fa8 <+160>: add    x0, x0, #0x49c            ; ::~Mutex() at Mutex.cpp:47
    0x10ce33fac <+164>: adrp   x1, 7435
    0x10ce33fb0 <+168>: add    x1, x1, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33fb4 <+172>: adrp   x2, -323
    0x10ce33fb8 <+176>: add    x2, x2, #0x0
    0x10ce33fbc <+180>: bl     0x10e5c48a8               ; symbol stub for: __cxa_atexit
    0x10ce33fc0 <+184>: adrp   x0, 7435
    0x10ce33fc4 <+188>: add    x0, x0, #0xa28            ; guard variable for MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33fc8 <+192>: bl     0x10e5c48fc               ; symbol stub for: __cxa_guard_release
    0x10ce33fcc <+196>: b      0x10ce33f24               ; <+28> [inlined] AutoLock at Mutex.h:33:59
    0x10ce33fd0 <+200>: mov    x19, x0
    0x10ce33fd4 <+204>: adrp   x0, 7435
    0x10ce33fd8 <+208>: add    x0, x0, #0xa28            ; guard variable for MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33fdc <+212>: bl     0x10e5c48e4               ; symbol stub for: __cxa_guard_abort
    0x10ce33fe0 <+216>: b      0x10ce33ff4               ; <+236> [inlined] ~AutoLock + 12 at Mutex.h
    0x10ce33fe4 <+220>: mov    x19, x0
    0x10ce33fe8 <+224>: adrp   x0, 7435
    0x10ce33fec <+228>: add    x0, x0, #0x9e0            ; MemoryManager::InitializeMemory()::s_initializeMemory
    0x10ce33ff0 <+232>: bl     0x10d3f14cc               ; ::Unlock() at Mutex.cpp:68:5
    0x10ce33ff4 <+236>: mov    x0, x19
    0x10ce33ff8 <+240>: bl     0x10e5c4380               ; symbol stub for: _Unwind_Resume
->  0x10ce33ffc <+244>: brk    #0x1
    0x10ce34000 <+248>: bl     0x10ccfb884               ; __clang_call_terminate
    0x10ce34004 <+252>: bl     0x10ccfb884               ; __clang_call_terminate

Screenshot 2022-09-19 at 22 35 07

I'm stuck for 3 days now :( I tried a lot of fixes nothing works :( any guidance, help or suggestions will be much appreciated!

danagbemava-nc wrote this answer on 2022-09-23

Hi @RoyalCoder88,

Can you please provide your flutter doctor -v and flutter run --verbose logs, and a minimal complete reproducible code sample?

Please also provide your pubspec.yaml, Podfile, and Podfile.lock files.

Thank you

RoyalCoder88 wrote this answer on 2022-09-24

Hi @danagbemava-nc

It's not a particular issue it's a big problem, also on Unity's forum

Regarding my project here you go:

flutter doctor
[✓] Flutter (Channel stable, 3.3.1, on macOS 12.6 21G115 darwin-arm, locale en-GB)
    • Flutter version 3.3.1 on channel stable at /Users/razvanu/Documents/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 4f9d92fbbd (3 weeks ago), 2022-09-06 17:54:53 -0700
    • Engine revision 3efdf03e73
    • Dart version 2.18.0
    • DevTools version 2.15.0

[✓] Android toolchain - develop for Android devices (Android SDK version 32.0.0)
    • Android SDK at /Users/razvanu/Library/Android/sdk
    • Platform android-33, build-tools 32.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
    • Xcode at /Applications/Xcode-14.1.0-Beta.2.app/Contents/Developer
    • Build 14B5024i
    • CocoaPods version 1.11.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2020.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[✓] VS Code (version 1.71.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.48.0

[✓] Connected device (2 available)
    • Buraca’s iPhone (mobile) • 00008110-001645D43C8A801E • ios            • iOS 16.0 20A362
    • Chrome (web)             • chrome                    • web-javascript • Google Chrome 105.0.5195.125

[✓] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!

flutter run --verbose:
verbose.txt


sample code:
sampleCode_Main.txt


pubspec.yaml:
pubspec.yaml.txt


Podfile:
Podfile.txt


Podfile.lock:
Podfile.lock.txt

Thanks in advance!

danagbemava-nc wrote this answer on 2022-09-26

Hi @RoyalCoder88, given that this issue is coming from Unity I'm not sure there's anything for the flutter team to do with regards to this.

As such I'm going to have to close this issue as this is not a flutter issue.

Thank you

More Details About Repo
Owner Name flutter
Repo Name flutter
Full Name flutter/flutter
Language Dart
Created Date 2015-03-06
Updated Date 2022-10-05
Star Count 145512
Watcher Count 3569
Fork Count 23398
Issue Count 11205

YOU MAY BE INTERESTED

Issue Title Created Date Comment Count Updated Date
Create pre-release or just tag beta? 1 2021-02-25 2022-08-06
v0.25.0 RC: `documents.add` right should not allow to create indexes 1 2021-12-20 2022-09-26
Generate runtime type check definition with the generic parameter of `FunctionalComponent` like seen with `defineProps` 3 2022-04-20 2022-09-01
Conda only dependency 6 2020-07-30 2022-07-10
Doesn't work when versions are of the form 3.5.8.29 2 2020-06-01 2022-07-10
One wrong character in the book 1 2021-02-17 2022-09-01
TypeError: Cannot read properties of null (reading 'license') when trying to use DRMToday licenses 4 2022-06-19 2022-09-18
Multicursor select_all_current keybinding not working 0 2022-09-16 2022-09-22
Terminal Command Autocompletion shows artefact 0 2022-09-17 2022-09-22
Android render not correctly 9 2019-08-02 2022-09-26
[Feature Request] import templates from file 2 2022-04-04 2022-09-13
Linux crash 29 2017-02-19 2022-01-03
Thank you very much for the author's sharing. I would like to ask if it supports remote connection drivers. 40 2022-04-16 2022-09-20
Roghayehkharazmi 0 2021-07-12 2022-01-16
How to keep state edit mode 4 2021-10-22 2022-09-01
Any idea why binaries precompiled with -no-pie would be any less likely to need a super high memory limit upon execveing? 2 2021-12-21 2022-09-16
DIYRuz Flower Sensor in 2.13.2 no ZHAMoisture detected 2 2021-11-17 2022-09-25
Add support for gamepad selection of OS 71 2016-06-12 2022-08-03
7.6.0 Type Annotation for DocumentCollection 8 2021-10-20 2022-09-27
How to debug aql-template queries? 1 2022-07-19 2022-09-27
maybe missing `isArangoError` check in catch? 2 2021-12-27 2022-09-27
Add Expand/collapse capability 3 2021-08-17 2022-09-22
Starting mcbserver: LinuxGSMno server running on /tmp/tmux-1000/default - Ubuntu 22.04 0 2022-09-10 2022-09-22
Necesse Dedicated Server [Server Request] 4 2022-09-03 2022-09-22
Redirect Policy cannot apply after user enrollment 8 2021-10-26 2022-09-15
Feature Request: `android.permission.MANAGE_EXTERNAL_STORAGE` permission 5 2021-12-10 2022-10-01
Resource key may be necessary to access certain shared files 7 2021-07-29 2022-09-25
using drive_find(q = "fullText contains 'insert_anything_here'") always returns an error 1 2021-09-02 2022-09-25
Feature request: add catkin configuration 1 2021-09-13 2022-09-25
werf bundle render with secret values file 0 2022-07-12 2022-09-28
[BUG]关于指定范围设定单元格格式“bd” 0 2021-08-18 2022-09-25
Question: ARM support for Docker on Raspberry Pi 17 2018-07-03 2022-09-27
New-IntuneWin32AppReturnCode missing type "Failed" 1 2021-09-04 2022-09-25
Migrating from coreos/prometheus-operator 0 2022-08-25 2022-09-19
Widget doesn’t update with days remaining 1 2021-05-20 2022-09-25
clarify that bash shortcut task only takes command(s) 1 2022-06-06 2022-09-26
Installer of the `Volo.Users` module is faulty 0 2021-12-03 2022-09-20
[API] Using massive actions 3 2022-04-27 2022-09-14
Export to CSV - problem with special characters in fields 2 2022-04-27 2022-09-14
Glpi 10.0 Page blanche marketplace 1 2022-04-27 2022-09-16
Feature: Implement Storage Write API 1 2022-01-14 2022-09-24
build(deps): bump y18n from 3.2.1 to 3.2.2 0 2021-03-30 2022-09-13
build: bump micronaut-gradle-plugins from 4.0.0 to 4.0.1 0 2021-08-23 2022-01-31
Decoder error with Lenovo Tablet 3 2022-07-11 2022-09-25
Can't bind the WebUI to port 80 with Docker at unRAID in macvlan 0 2021-01-20 2022-08-17
Add the new GUC `citus.stat_statements_track` to docs 0 2021-08-03 2022-09-17
What is the difference between the Prometheus metrics - nginx_ingress_controller_ingress_upstream_latency_seconds_sum and nginx_ingress_controller_response_duration_seconds_bucket ? 8 2021-10-31 2022-08-09
How to publish in grayscale based on custom request headers 11 2021-11-01 2022-09-30
TransitionRoot fails to show enter transition when multiple transition-group is present 2 2022-02-04 2022-09-28
XL version customization not working completely 1 2021-06-29 2022-09-14