Hi I've submitted my game to iTunes Connect the other day and unfortunately it got rejected due to the game crashes (it doesn't crash when I'm testing it, even though I used the same iOS version). They gave me the crash log and I've symbolicate it (using the method from here: https://medium.com/#Mrugraj/crash-re-symbolication-5c28d3a3a883) to find the problem and got this:
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread: 0
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x00000001964fb270 __pthread_kill + 8
1 libsystem_pthread.dylib 0x000000019659916c pthread_kill + 108
2 libsystem_c.dylib 0x0000000196472b14 abort + 108
3 libsystem_c.dylib 0x0000000196447a38 __assert_rtn + 88
4 Metal 0x0000000186b93b0c MTLReportFailure + 452
5 Metal 0x0000000186b6b24c validateWritePixels + 704
6 AGXMetal 0x0000000105994c44 0x10597c000 + 101444
7 AGXMetal 0x00000001059bc084 0x10597c000 + 262276
8 Metal 0x0000000186b6ce80 -[MTLIOAccelTexture replaceRegion:mipmapLevel:withBytes:bytesPerRow:] + 76
9 HitAndRescue 0x0000000100970208 TexturesMetal::UploadTextureSubData2D(TextureID, unsigned char const*, int, int, int, int, int, TextureFormat, TextureColorSpace) (TexturesMetal.mm:253)
10 HitAndRescue 0x000000010096b4e0 GfxDeviceMetal::UploadTextureSubData2D(TextureID, unsigned char const*, int, int, int, int, int, int, TextureFormat, TextureColorSpace) (GfxDeviceMetal.mm:1722)
11 HitAndRescue 0x000000010091510c TextRenderingPrivate::Font::AddCharacterToTexture(unsigned int, int, unsigned int) (Font.cpp:685)
12 HitAndRescue 0x000000010091564c TextRenderingPrivate::Font::CacheFontForText(unsigned short*, int, int, unsigned int, std::__1::vector<TextRenderingPrivate::TextFormatChange, std::__1::allocator<TextRenderingPrivate::TextFormatChange> >) (Font.cpp:827)
13 HitAndRescue 0x0000000100922c54 TextRenderingPrivate::NativeTextGenerator::Setup() (TextGenerator.cpp:208)
14 HitAndRescue 0x0000000100926db0 TextRenderingPrivate::TextMeshGenerator::Generate() (TextMeshGenerator.cpp:294)
15 HitAndRescue 0x0000000100926c0c TextRenderingPrivate::TextMeshGenerator::Get(UTF16String const&, TextRenderingPrivate::Font*, TextAnchor, TextAlignment, float, float, float, bool, bool, ColorRGBA32, int, int) (TextMeshGenerator.cpp:99)
16 HitAndRescue 0x0000000100911620 TextRenderingModule::TMGenGet(UTF16String const&, TextRendering::Font*, TextAnchor, TextAlignment, float, float, float, bool, bool, ColorRGBA32, int, int) const (TextRenderingModule.cpp:20)
17 HitAndRescue 0x0000000100654798 IMGUI::GetGenerator(RectT<float> const&, GUIContent const&, TextRendering::Font*, TextAnchor, bool, bool, ColorRGBA32, int, int, ImagePosition) (IMGUIUtils.cpp:77)
18 HitAndRescue 0x0000000100650db4 GUIStyle::GetGenerator(RectT<float> const&, GUIContent&) const (GUIStyle.cpp:598)
19 HitAndRescue 0x000000010065108c GUIStyle::CalcSize(GUIContent&) const (GUIStyle.cpp:435)
20 HitAndRescue 0x000000010095f604 GUIStyle_CUSTOM_Internal_CalcSize(void*, ScriptingObject*, Vector2fIcall*) (GUIStyleBindings.gen.cpp:660)
21 HitAndRescue 0x0000000100238490 GUIStyle_CalcSize_m2752 (Bulk_UnityEngine_0.cpp:17509)
22 HitAndRescue 0x0000000100066c10 GUIHelper_GetSuggestedFontSizeFull_m1719 (Bulk_Assembly-CSharp_0.cpp:33257)
23 HitAndRescue 0x00000001000a8f84 SignupScreen_InitLayoutVariable_m2399 (Bulk_Assembly-CSharp_1.cpp:23558)
24 HitAndRescue 0x00000001000a5e2c SignupScreen__ctor_m2394 (Bulk_Assembly-CSharp_1.cpp:23316)
25 HitAndRescue 0x00000001000a5b70 LoginScreen_Start_m2349 (Bulk_Assembly-CSharp_1.cpp:21572)
26 HitAndRescue 0x00000001003c2da4 RuntimeInvoker_Void_t189(MethodInfo const*, void*, void**) (GeneratedInvokers.cpp:12)
27 HitAndRescue 0x0000000100dd09e0 il2cpp::vm::Runtime::Invoke(MethodInfo const*, void*, void**, Il2CppObject**) (Runtime.cpp:299)
28 HitAndRescue 0x00000001006d4f24 ScriptingInvocation::Invoke(ScriptingException**, bool) (ScriptingInvocation.cpp:128)
29 HitAndRescue 0x00000001006cf1c4 MonoBehaviour::InvokeMethodOrCoroutineChecked(ScriptingMethodIl2Cpp, ScriptingObject*, ScriptingException**) (MonoBehaviour.cpp:844)
30 HitAndRescue 0x00000001006cf710 MonoBehaviour::InvokeMethodOrCoroutineChecked(ScriptingMethodIl2Cpp, ScriptingObject*) (MonoBehaviour.cpp:926)
31 HitAndRescue 0x00000001006ce6bc MonoBehaviour::DoGUI(MonoBehaviour::GUILayoutType, int) (MonoBehaviour.cpp:358)
32 HitAndRescue 0x000000010064cd64 GUIManager::DoGUIEvent(InputEvent&, bool) (GUIManager.cpp:315)
33 HitAndRescue 0x000000010064d2b4 GUIManager::SendQueuedEvents() (GUIManager.cpp:142)
34 HitAndRescue 0x0000000100683d68 PlayerLoop(bool, bool, IHookEvent*) (Player.cpp:1829)
35 HitAndRescue 0x0000000100487024 UnityPlayerLoopImpl(bool) (LibEntryPoint.mm:235)
36 HitAndRescue 0x000000010000b47c UnityRepaint (UnityAppController+Rendering.mm:246)
37 HitAndRescue 0x000000010000b2e0 __51-[UnityAppController(Rendering) repaintDisplayLink]_block_invoke (UnityAppController+Rendering.mm:52)
38 libdispatch.dylib 0x00000001963b5990 _dispatch_call_block_and_release + 20
39 libdispatch.dylib 0x00000001963b5950 _dispatch_client_callout + 12
40 libdispatch.dylib 0x00000001963ba208 _dispatch_main_queue_callback_4CF + 1604
41 CoreFoundation 0x000000018411f7f4 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 8
42 CoreFoundation 0x000000018411d89c __CFRunLoopRun + 1488
43 CoreFoundation 0x00000001840492d0 CFRunLoopRunSpecific + 392
44 GraphicsServices 0x000000018d9776f8 GSEventRunModal + 164
45 UIKit 0x0000000188c46f3c UIApplicationMain + 1484
46 HitAndRescue 0x00000001000055d0 main (main.mm:40)
47 libdyld.dylib 0x00000001963e2a04 start + 0
There are other threads but the one that crashed was this one so I'm posting only posting this. The part that hints crashed seems to be no4; "MTLReportFailure" but I can't find much info on it, while the last of my function being called seems to be on no22; "GetSuggestedFontSizeFull".
Can anybody help me, which one is the cause here? If it's the Metal's function, how can I fixed that (I'm developing with Unity3D)?
Edit:
So I've tested the game after installing it through TestFlight since this should make sure that I'm using the same exact thing as Apple's tester. And the game still didn't crash (I removed the game from the device first before installing it through TestFlight). So I'm totally not sure what to do now.
Related
I’m getting the following crash when using AVAudioSession with AVAudioEngine. What I don’t understand is why InterruptionListener is listed twice in the stack trace. Does this mean it’s somehow being called again before it has returned? Is this likely to be a concurrency issue?
Crashed: AVAudioSession Notify Thread
0 libEmbeddedSystemAUs.dylib 0x1dbc3333c InterruptionListener(void*, unsigned int, unsigned int, void const*)
1 libEmbeddedSystemAUs.dylib 0x1dbc33270 InterruptionListener(void*, unsigned int, unsigned int, void const*)
2 AudioToolbox 0x1c86e6484 AudioSessionPropertyListeners::CallPropertyListeners(unsigned int, unsigned int, void const*) + 596
3 AudioToolbox 0x1c8740798 HandleAudioSessionCFTypePropertyChangedMessage(unsigned int, unsigned int, void*, unsigned int) + 1144
4 AudioToolbox 0x1c873fec0 ProcessDeferredMessage(unsigned int, __CFData const*, unsigned int, unsigned int) + 2452
5 AudioToolbox 0x1c873f17c ASCallbackReceiver_AudioSessionPingMessage + 632
6 AudioToolbox 0x1c87ad398 _XAudioSessionPingMessage + 44
7 libAudioToolboxUtility.dylib 0x1c8840430 mshMIGPerform + 264
8 CoreFoundation 0x1bd42b174 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56
9 CoreFoundation 0x1bd42a880 __CFRunLoopDoSource1 + 444
10 CoreFoundation 0x1bd425634 __CFRunLoopRun + 1888
11 CoreFoundation 0x1bd424ba8 CFRunLoopRunSpecific + 424
12 AVFAudio 0x1ca1f4a2c GenericRunLoopThread::Entry(void*) + 156
13 AVFAudio 0x1ca2457a0 CAPThread::Entry(CAPThread*) + 204
14 libsystem_pthread.dylib 0x1bd1c2d98 _pthread_start + 156
15 libsystem_pthread.dylib 0x1bd1c674c thread_start + 8
(I've found some other QuartzCore crash related questions on StackOverflow but none of them are for the exact context that we have.)
We have an iOS app in the App Store. Recently, we see in Organizer / Crashes for that app a new type of crash that seems bound to iOS 13 devices (21 devices affected in the last few weeks, all with iOS 13.1, .2, or .3). Xcode reports that the crashes occurred in QuartzCore, on CA::Render::Encoder::grow(unsigned long).
Any idea what can it be and how it could be fixed? It doesn't look related to our code. Can it be a recent Apple bug? (We didn't have these crash reports before iOS 13.) Thank you in advance.
Here is an extract from the crash log:
OS Version: iPhone OS 13.3 (17C54)
Release Type: User
Baseband Version: 2.03.07
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Triggered by Thread: 0
Thread 0 name:
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x00000001b431aefc __pthread_kill + 8
1 libsystem_pthread.dylib 0x00000001b423a8b8 pthread_kill + 228 (pthread.c:1458)
2 libsystem_c.dylib 0x00000001b41caa74 abort + 104 (abort.c:110)
3 QuartzCore 0x00000001bb0fc3b0 CA::Render::Encoder::grow(unsigned long) + 308 (render-coding.cpp:562)
4 QuartzCore 0x00000001bb0fcb20 CA::Render::Encoder::encode_data_async(void const*, unsigned long, void (*)(void const*, void*), ... + 180 (render-coding.h:272)
5 QuartzCore 0x00000001bafb2f78 CA::Render::Image::encode(CA::Render::Encoder*) const + 740 (render-image.cpp:401)
6 QuartzCore 0x00000001bb0fc438 CA::Render::Encoder::encode_object_uncached(CA::Render::Object const*) + 136 (render-coding.cpp:905)
7 QuartzCore 0x00000001bafcf9d4 CA::Render::Layer::encode(CA::Render::Encoder*) const + 116 (render-coding.h:388)
8 QuartzCore 0x00000001bb0fc438 CA::Render::Encoder::encode_object_uncached(CA::Render::Object const*) + 136 (render-coding.cpp:905)
9 QuartzCore 0x00000001bb100ebc CA::Render::encode_set_object(CA::Render::Encoder*, unsigned long, unsigned int, CA::Render::Obje... + 196 (render-coding.cpp:2151)
10 QuartzCore 0x00000001bb04094c invocation function for block in CA::Context::commit_transaction(CA::Transaction*, double) + 1080 (CAContextInternal.mm:1632)
11 QuartzCore 0x00000001bb0fae1c CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 348 (CALayer.mm:2647)
12 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
13 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
14 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
15 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
16 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
17 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
18 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
19 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
20 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
21 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
22 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
23 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
24 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
25 QuartzCore 0x00000001bb0fad98 CA::Layer::commit_if_needed(CA::Transaction*, void (CA::Layer*, unsigned int, unsigned int) block... + 216 (CALayer.mm:2633)
26 QuartzCore 0x00000001bb03fbc4 CA::Context::commit_transaction(CA::Transaction*, double) + 2868 (CAContextInternal.mm:2288)
27 QuartzCore 0x00000001bb069fd0 CA::Transaction::commit() + 684 (CATransactionInternal.mm:438)
28 UIKitCore 0x00000001b8648d60 _afterCACommitHandler + 144 (UIApplication.m:3076)
29 CoreFoundation 0x00000001b44ab524 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 36 (CFRunLoop.c:1758)
30 CoreFoundation 0x00000001b44a61c4 __CFRunLoopDoObservers + 420 (CFRunLoop.c:1868)
31 CoreFoundation 0x00000001b44a6774 __CFRunLoopRun + 1292 (CFRunLoop.c:2910)
32 CoreFoundation 0x00000001b44a5f40 CFRunLoopRunSpecific + 480 (CFRunLoop.c:3192)
33 GraphicsServices 0x00000001be723534 GSEventRunModal + 108 (GSEvent.c:2246)
34 UIKitCore 0x00000001b861ea60 UIApplicationMain + 1940 (UIApplication.m:4773)
35 <Our app name> 0x00000001029ed048 main + 88 (main.m:14)
36 libdyld.dylib 0x00000001b4324e18 start + 4
I get Xcode quit unexpectedly while using the SimplePlayer plug-in.
simpleplayer is the name of the app.
Xcode 6.2 only happens in simulator. IOS target 8.1 and above. App works normal without breakpoint.
This only happens when I set the breakpoint in the completion callback.
Time Awake Since Boot: 530 seconds
Crashed Thread: 21 <lldb.process.internal-state(pid=1263)>
Exception Type: EXC_BAD_ACCESS (Code Signature Invalid)
Exception Codes: 0x0000000000000032, 0x000000014057b3bc
kernel messages:
-1 sec CODE SIGNING: cs_invalid_page(0x14057b000): p=1151[Xcode] final status 0x3004200, denying page sending SIGKILL
-1 sec CODE SIGNING: process 1151[Xcode]: rejecting invalid page at address 0x14057b000 from offset 0x225000 in file "/Users/USER/Library/Developer/CoreSimulator/Devices/C7E8D457-BFAB-43DA-8B0C-D9010BBB1D88/data/Containers/Bundle/Application/77AB1811-69B6-4079-B874-8E20A7160283/SimplePlayer.app/SimplePlayer" (cs_mtime:1427477037.0 == mtime:1427477037.0) (signed:1 validated:1 tainted:1 wpmapped:0 slid:0)
Thread 21 Crashed:: <lldb.process.internal-state(pid=1263)>
0 com.apple.LLDB.framework 0x000000010f2961f4 lldb_private::DataExtractor::GetU32_unchecked(unsigned long long*) const + 14
1 com.apple.LLDB.framework 0x000000010f39af99 ObjectFileMachO::ParseSymtab() + 3603
2 com.apple.LLDB.framework 0x000000010f39a0f2 ObjectFileMachO::GetSymtab() + 158
3 com.apple.LLDB.framework 0x000000010f43f238 lldb_private::SymbolVendor::GetSymtab() + 64
4 com.apple.LLDB.framework 0x000000010f2da04f lldb_private::Module::ResolveSymbolContextForAddress(lldb_private::Address const&, unsigned int, lldb_private::SymbolContext&, bool) + 333
5 com.apple.LLDB.framework 0x000000010f287295 lldb_private::Address::CalculateSymbolContext(lldb_private::SymbolContext*, unsigned int) const + 157
6 com.apple.LLDB.framework 0x000000010f42dede lldb_private::CompileUnit::ResolveSymbolContext(lldb_private::FileSpec const&, unsigned int, bool, bool, unsigned int, lldb_private::SymbolContextList&) + 630
7 com.apple.LLDB.framework 0x000000010f23b32b lldb_private::BreakpointResolverFileLine::SearchCallback(lldb_private::SearchFilter&, lldb_private::SymbolContext&, lldb_private::Address*, bool) + 217
8 com.apple.LLDB.framework 0x000000010f2efc8b lldb_private::SearchFilter::DoModuleIteration(lldb_private::SymbolContext const&, lldb_private::Searcher&) + 129
9 com.apple.LLDB.framework 0x000000010f2f00dc lldb_private::SearchFilter::DoModuleIteration(std::__1::shared_ptr<lldb_private::Module> const&, lldb_private::Searcher&) + 86
10 com.apple.LLDB.framework 0x000000010f2effc7 lldb_private::SearchFilter::SearchInModuleList(lldb_private::Searcher&, lldb_private::ModuleList&) + 241
11 com.apple.LLDB.framework 0x000000010f23339e lldb_private::Breakpoint::ModulesChanged(lldb_private::ModuleList&, bool, bool) + 772
12 com.apple.LLDB.framework 0x000000010f235955 lldb_private::BreakpointList::UpdateBreakpoints(lldb_private::ModuleList&, bool, bool) + 77
13 com.apple.LLDB.framework 0x000000010f4798ab lldb_private::Target::ModulesDidLoad(lldb_private::ModuleList&) + 69
14 com.apple.LLDB.framework 0x000000010f4797d6 lldb_private::Target::ModuleAdded(lldb_private::ModuleList const&, std::__1::shared_ptr<lldb_private::Module> const&) + 444
15 com.apple.LLDB.framework 0x000000010f2ddfad lldb_private::ModuleList::AppendImpl(std::__1::shared_ptr<lldb_private::Module> const&, bool) + 135
16 com.apple.LLDB.framework 0x000000010f47909c lldb_private::Target::GetSharedModule(lldb_private::ModuleSpec const&, lldb_private::Error*) + 1576
17 com.apple.LLDB.framework 0x000000010f3883b3 DynamicLoaderMacOSXDYLD::FindTargetModuleForDYLDImageInfo(DynamicLoaderMacOSXDYLD::DYLDImageInfo&, bool, bool*) + 331
18 com.apple.LLDB.framework 0x000000010f38a28c DynamicLoaderMacOSXDYLD::UpdateImageInfosHeaderAndLoadCommands(std::__1::vector<DynamicLoaderMacOSXDYLD::DYLDImageInfo, std::__1::allocator<DynamicLoaderMacOSXDYLD::DYLDImageInfo> >&, unsigned int, bool) + 256
19 com.apple.LLDB.framework 0x000000010f3898e5 DynamicLoaderMacOSXDYLD::AddModulesUsingImageInfosAddress(unsigned long long, unsigned int) + 153
20 com.apple.LLDB.framework 0x000000010f389744 DynamicLoaderMacOSXDYLD::NotifyBreakpointHit(void*, lldb_private::StoppointCallbackContext*, unsigned long long, unsigned long long) + 528
21 com.apple.LLDB.framework 0x000000010f23a146 lldb_private::BreakpointOptions::InvokeCallback(lldb_private::StoppointCallbackContext*, unsigned long long, unsigned long long) + 48
22 com.apple.LLDB.framework 0x000000010f237462 lldb_private::BreakpointLocation::InvokeCallback(lldb_private::StoppointCallbackContext*) + 82
23 com.apple.LLDB.framework 0x000000010f237bc5 lldb_private::BreakpointLocation::ShouldStop(lldb_private::StoppointCallbackContext*) + 115
24 com.apple.LLDB.framework 0x000000010f238816 lldb_private::BreakpointLocationCollection::ShouldStop(lldb_private::StoppointCallbackContext*) + 76
25 com.apple.LLDB.framework 0x000000010f240a74 lldb_private::BreakpointSite::ShouldStop(lldb_private::StoppointCallbackContext*) + 48
26 com.apple.LLDB.framework 0x000000010f4739e4 lldb_private::StopInfoBreakpoint::ShouldStopSynchronous(lldb_private::Event*) + 232
27 com.apple.LLDB.framework 0x000000010f487a1c lldb_private::Thread::ShouldStop(lldb_private::Event*) + 650
28 com.apple.LLDB.framework 0x000000010f48d285 lldb_private::ThreadList::ShouldStop(lldb_private::Event*) + 483
29 com.apple.LLDB.framework 0x000000010f46286d lldb_private::Process::ShouldBroadcastEvent(lldb_private::Event*) + 379
30 com.apple.LLDB.framework 0x000000010f46065e lldb_private::Process::HandlePrivateEvent(std::__1::shared_ptr<lldb_private::Event>&) + 356
31 com.apple.LLDB.framework 0x000000010f46305b lldb_private::Process::RunPrivateStateThread() + 511
32 com.apple.LLDB.framework 0x000000010f462a61 lldb_private::Process::PrivateStateThread(void*) + 9
33 libsystem_pthread.dylib 0x00007fff8cedc268 _pthread_body + 131
34 libsystem_pthread.dylib 0x00007fff8cedc1e5 _pthread_start + 176
35 libsystem_pthread.dylib 0x00007fff8ceda41d thread_start + 13
I have the following stack trace:
Crashed: tcpConnWorkQueue (Not main thread)
EXC_BAD_ACCESS KERN_INVALID_ADDRESS at 0xf000000c
0 libobjc.A.dylib objc_msgSend + 5
1 CoreFoundation CFRelease + 560
2 libdispatch.dylib _dispatch_call_block_and_release + 10
3 libdispatch.dylib _dispatch_queue_drain + 374
4 libdispatch.dylib _dispatch_queue_invoke + 42
5 libdispatch.dylib _dispatch_root_queue_drain + 76
6 libdispatch.dylib _dispatch_worker_thread2 + 56
7 libsystem_pthread.dylib _pthread_wqthread + 298
All the other stacks look unrelated to my code. What does this stack trace mean? And where can I look for faults in my code that may lead to something like this?
Main thread stack look like this:
Thread : com.apple.main-thread
0 QuartzCore 0x2fedef34 CA::Render::Object::unref() const + 35
1 QuartzCore 0x2fedda73 CA::Context::commit_layer(CA::Layer*, unsigned int, unsigned int, void*) + 142
2 QuartzCore 0x2fedda73 CA::Context::commit_layer(CA::Layer*, unsigned int, unsigned int, void*) + 142
3 QuartzCore 0x2fedaa23 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 314
4 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
5 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
6 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
7 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
8 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
9 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
10 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
11 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
12 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
13 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
14 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
15 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
16 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
17 QuartzCore 0x2feda9c1 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 216
18 QuartzCore 0x2fed8d41 CA::Context::commit_transaction(CA::Transaction*) + 1048
19 QuartzCore 0x2fed881f CA::Transaction::commit() + 314
20 QuartzCore 0x2ff2d929 CA::Display::DisplayLink::dispatch_items(unsigned long long, unsigned long long, unsigned long long) + 516
21 IOMobileFramebuffer 0x32b5d76d IOMobileFramebufferVsyncNotifyFunc + 104
22 IOKit 0x2e7b4be5 IODispatchCalloutFromCFMessage + 248
23 CoreFoundation 0x2da92b81 __CFMachPortPerform + 136
24 CoreFoundation 0x2da9d777 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34
25 CoreFoundation 0x2da9d713 __CFRunLoopDoSource1 + 346
26 CoreFoundation 0x2da9bedf __CFRunLoopRun + 1406
27 CoreFoundation 0x2da06471 CFRunLoopRunSpecific + 524
28 CoreFoundation 0x2da06253 CFRunLoopRunInMode + 106
29 GraphicsServices 0x327402eb GSEventRunModal + 138
30 UIKit 0x302bb845 UIApplicationMain + 1136
The stack trace, at level 1, shows a CFRelease has been called, but your address 0xf000000c is invalid according to the kernel, resulting in a bad access exception. This happens when a message is sent to an object already released, in the most common case.
This type of crash usually has a time lag between when the object was first released, and when it was released a second time. However, you have code which triggers when the screen is updated because you have a 0x2ff2d929 CA::Display::DisplayLink::dispatch_items.
The screen updates frequently so this should be called often.
Have you used + (CADisplayLink *)displayLinkWithTarget:(id)target selector:(SEL)sel anywhere in your program? Do you have any - (void)invalidate calls?
It could be that the user interface is switching from one use case (say playing a game with display timer based screen updates) to another (say presenting a menu choice when the game ends). When this kind of switch occurs, the code assumptions are invalidated, so you have to cancel your callbacks, else you get a final callback when things are not setup right (you draw a frame of a game when actually its time to present menus).
When you run your program with Zombies enabled -- a tick box in the Schema section, then any Released object is made a "zombie" - it lingers around waiting for calls to be made on the object. When any call comes in, it knows its a programming error and aborts. Then you can look back at the allocation history of that object to see where it was first allocated and released to identify the double-release bug.
my app crash in IMGSGX543GLDriver ,the most difficult is there are not any code of my app in the crash log and i cannot reproduce it .This issue cost me several days and I still have no idea. Any ideas you guys provide, I will try. Thank you for your help.
Thread 12 name: Dispatch queue: CA::CG::Queue
Thread 12 Crashed:
0 IMGSGX543GLDriver 0x31cb4ff0 glrRetainVendCtxPipeProg + 0
1 IMGSGX543GLDriver 0x31caf8d8 gpusLoadCurrentPipelinePrograms + 1664
2 IMGSGX543GLDriver 0x31cb948c gldUpdateDispatch + 396
3 GLEngine 0x34184a0a gleDoDrawDispatchCoreES2 + 562
4 GLEngine 0x3412ef72 glDrawElements_IMM_ES2Exec + 190
5 QuartzCore 0x331bffc4 CA::OGL::GLContext::draw_elements(CA::OGL::PrimitiveMode, unsigned int, unsigned short const*, CA::OGL::Vertex const*, unsigned int, unsigned int, CA::OGL::ClipPlane const*) + 272
6 QuartzCore 0x331bfe7c CA::OGL::Context::array_flush() + 48
7 QuartzCore 0x331ef8ae CA::OGL::emit_combine_(CA::OGL::Context&, CA::OGL::TextureFunction, CA::OGL::Surface*, int, CA::OGL::Surface*, int, CA::OGL::Surface*, int, CA::Shape const*, CA::Vec4<float> const&) + 1114
8 QuartzCore 0x331ef444 CA::OGL::emit_combine(CA::OGL::Context&, CA::OGL::TextureFunction, CA::OGL::Surface*, int, CA::OGL::Surface*, int, CA::OGL::Surface*, int, CA::Shape const*, CA::Vec4<float> const&) + 112
9 QuartzCore 0x331e3560 CA::CG::DrawOp::render(CA::CG::Renderer&) const + 1940
10 QuartzCore 0x331e1854 CA::CG::Queue::render_callback(void*) + 116
11 libdispatch.dylib 0x346e4d08 _dispatch_queue_drain + 268
12 libdispatch.dylib 0x346e4b6e _dispatch_queue_invoke$VARIANT$mp + 34
13 libdispatch.dylib 0x346e57e0 _dispatch_worker_thread2 + 204
14 libsystem_c.dylib 0x32f67df4 _pthread_wqthread + 288
15 libsystem_c.dylib 0x32f67cc8 start_wqthread + 0