Random crashes in IOS - ios

I have this app in the app store, which according to Crashalitics, its %92-%95 stable. I made a similar app for Android and its around 98% stable. I am trying to get the stability up - but I don't see how. All the bugs I am seeing in the IOS version are not touching my code.
I see random bugs, that are not reproducible, and when they do are very random. Each happens 1-10 times, but I have a list of ... ~30 different items.
The app is pretty simple - a mostly linear storyboard (a few jumps, but no loops). The only project I am using which is not Apple's code is InAppSettingsKit, and most of the app is just maps which shows some items. The project is using ARC and currently compiled using XCode6 (but XCode5 showed the same symptoms).
How can I find these crashes? Is this in an inherent problem of IOS7-8? I do see some apps just closing up when I use the IPhone, and friends to tell me that IOS is not that stable, but ... I just think I am doing something wrong.
IOS8 70% IOS7 30%
Thread : Crashed: com.apple.main-thread
0 libobjc.A.dylib 0x36444f66 objc_msgSend + 5
1 UIKit 0x2c160b35 -[UIScrollView(UIScrollViewInternal) _delegateScrollViewAnimationEnded] + 52
2 UIKit 0x2c160ac1 -[UIScrollView(UIScrollViewInternal) _scrollViewAnimationEnded:finished:] + 184
3 UIKit 0x2c20a5e5 -[UIAnimator stopAnimation:] + 476
4 UIKit 0x2c209fb9 -[UIAnimator(Static) _advanceAnimationsOfType:withTimestamp:] + 304
5 UIKit 0x2c209e85 -[UIAnimator(Static) _LCDHeartbeatCallback:] + 52
6 QuartzCore 0x2bae4aeb CA::Display::DisplayLinkItem::dispatch() + 98
7 QuartzCore 0x2bae4953 CA::Display::DisplayLink::dispatch_items(unsigned long long, unsigned long long, unsigned long long) + 366
8 IOMobileFramebuffer 0x303c482f IOMobileFramebufferVsyncNotifyFunc + 90
9 IOKit 0x29af01ed IODispatchCalloutFromCFMessage + 256
10 CoreFoundation 0x28b7c3a5 __CFMachPortPerform + 132
11 CoreFoundation 0x28b8c7f3 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34
12 CoreFoundation 0x28b8c78f __CFRunLoopDoSource1 + 346
13 CoreFoundation 0x28b8adb1 __CFRunLoopRun + 1608
14 CoreFoundation 0x28ad7b31 CFRunLoopRunSpecific + 476
15 CoreFoundation 0x28ad7943 CFRunLoopRunInMode + 106
16 GraphicsServices 0x2feb7051 GSEventRunModal + 136
17 UIKit 0x2c0cd6f1 UIApplicationMain + 1440
18 --------------- 0x000c8833 main (main.m:16)
IOS7 - 8 times
Thread : Fatal Exception: NSInvalidArgumentException
0 CoreFoundation 0x2e23ef83 __exceptionPreprocess + 130
1 libobjc.A.dylib 0x389efccf objc_exception_throw + 38
2 CoreFoundation 0x2e242917 -[NSObject(NSObject) doesNotRecognizeSelector:] + 202
3 CoreFoundation 0x2e241203 ___forwarding___ + 706
4 CoreFoundation 0x2e190768 _CF_forwarding_prep_0 + 24
5 VectorKit 0x35ec6911 -[VKMapCanvas initShouldRasterize:contentScale:inBackground:] + 476
6 VectorKit 0x35ec620f -[VKMapView initWithGlobe:shouldRasterize:inBackground:] + 230
7 MapKit 0x2f3d980b -[MKBasicMapView initWithFrame:andGlobe:shouldRasterize:] + 322
8 MapKit 0x2f40cd77 -[MKMapView _commonInitAndEnableLoading:fromIB:gestureRecognizerHostView:showsAttribution:] + 878
9 MapKit 0x2f40d86b -[MKMapView initWithCoder:] + 134
10 UIKit 0x30e70169 UINibDecoderDecodeObjectForValue + 740
11 UIKit 0x30e6fe7f -[UINibDecoder decodeObjectForKey:] + 90
12 UIKit 0x30dcb5ff -[UIRuntimeConnection initWithCoder:] + 150
13 UIKit 0x30e70169 UINibDecoderDecodeObjectForValue + 740
14 UIKit 0x30e70109 UINibDecoderDecodeObjectForValue + 644
15 UIKit 0x30e6fe7f -[UINibDecoder decodeObjectForKey:] + 90
16 UIKit 0x30dcadd1 -[UINib instantiateWithOwner:options:] + 888
17 UIKit 0x30d2360b -[UIViewController _loadViewFromNibNamed:bundle:] + 234
18 UIKit 0x30b7fbcd -[UIViewController loadView] + 92
19 UIKit 0x30a602ed -[UIViewController loadViewIfRequired] + 72
20 UIKit 0x30a60269 -[UIViewController view] + 24
21 UIKit 0x30b0a14b -[UINavigationController _startTransition:fromViewController:toViewController:] + 198
22 UIKit 0x30b09dfd -[UINavigationController _startDeferredTransitionIfNeeded:] + 572
23 UIKit 0x30b09b6d -[UINavigationController __viewWillLayoutSubviews] + 44
24 UIKit 0x30b09b05 -[UILayoutContainerView layoutSubviews] + 184
25 UIKit 0x30a5bd59 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 380
26 QuartzCore 0x306d962b -[CALayer layoutSublayers] + 142
27 QuartzCore 0x306d4e3b CA::Layer::layout_if_needed(CA::Transaction*) + 350
28 QuartzCore 0x30703cdd -[CALayer layoutIfNeeded] + 140
29 UIKit 0x30ad8163 -[UIViewController window:setupWithInterfaceOrientation:] + 242
30 UIKit 0x30ad6783 -[UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:isRotating:] + 3498
31 UIKit 0x30ad59d3 -[UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:] + 46
32 UIKit 0x30ad595b -[UIWindow _setRotatableViewOrientation:updateStatusBar:duration:force:] + 94
33 UIKit 0x30ad58f3 -[UIWindow _setRotatableViewOrientation:duration:force:] + 42
34 UIKit 0x30acdf69 __57-[UIWindow _updateToInterfaceOrientation:duration:force:]_block_invoke + 108
35 UIKit 0x30a62107 -[UIWindow _updateToInterfaceOrientation:duration:force:] + 382
36 UIKit 0x30ad5641 -[UIWindow setAutorotates:forceUpdateInterfaceOrientation:] + 696
37 UIKit 0x30ad5105 -[UIViewController _tryBecomeRootViewControllerInWindow:] + 164
38 UIKit 0x30a67045 -[UIWindow addRootViewControllerViewIfPossible] + 460
39 UIKit 0x30a64827 -[UIWindow _setHidden:forced:] + 302
40 UIKit 0x30ace33d -[UIWindow makeKeyAndVisible] + 60
41 UIKit 0x30acafad -[UIApplication _callInitializationDelegatesForURL:payload:suspended:] + 1820
42 UIKit 0x30ac556b -[UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 714
43 UIKit 0x30a616e9 -[UIApplication handleEvent:withNewEvent:] + 3540
44 UIKit 0x30a60851 -[UIApplication sendEvent:] + 72
45 UIKit 0x30ac4ca9 _UIApplicationHandleEvent + 616
46 GraphicsServices 0x33079aed _PurpleEventCallback + 608
47 GraphicsServices 0x330796d7 PurpleEventCallback + 34
48 CoreFoundation 0x2e209a67 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34
49 CoreFoundation 0x2e209a03 __CFRunLoopDoSource1 + 346
50 CoreFoundation 0x2e2081d7 __CFRunLoopRun + 1398
51 CoreFoundation 0x2e172ebf CFRunLoopRunSpecific + 522
52 CoreFoundation 0x2e172ca3 CFRunLoopRunInMode + 106
53 UIKit 0x30ac3ed1 -[UIApplication _run] + 760
54 UIKit 0x30abf14d UIApplicationMain + 1136
55 --------------- 0x000ef833 main (main.m:16)
56 libdyld.dylib 0x38efcab7 start + 2
Another (IOS 6.1.6)
vThread : Fatal Exception: NSGenericException
0 CoreFoundation 0x31eaf2a3 __exceptionPreprocess + 162
1 libobjc.A.dylib 0x39b0b97f objc_exception_throw + 30
2 UIKit 0x3404d30f -[UIStoryboardPushSegue perform] + 1118
3 UIKit 0x33da20c5 -[UIApplication sendAction:to:from:forEvent:] + 72
4 UIKit 0x33da214d -[UIBarButtonItem(UIInternal) _sendAction:withEvent:] + 120
5 UIKit 0x33da20c5 -[UIApplication sendAction:to:from:forEvent:] + 72
6 UIKit 0x33da2077 -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 30
7 UIKit 0x33da2055 -[UIControl sendAction:to:forEvent:] + 44
8 UIKit 0x33da190b -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 502
9 UIKit 0x33da1e01 -[UIControl touchesEnded:withEvent:] + 488
10 UIKit 0x33cca5f1 -[UIWindow _sendTouchesForEvent:] + 524
11 UIKit 0x33cb7801 -[UIApplication sendEvent:] + 380
12 UIKit 0x33cb711b _UIApplicationHandleEvent + 6154
13 GraphicsServices 0x359735a3 _PurpleEventCallback + 590
14 GraphicsServices 0x359731d3 PurpleEventCallback + 34
15 CoreFoundation 0x31e84173 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 34
16 CoreFoundation 0x31e84117 __CFRunLoopDoSource1 + 138
17 CoreFoundation 0x31e82f99 __CFRunLoopRun + 1384
18 CoreFoundation 0x31df5ebd CFRunLoopRunSpecific + 356
19 CoreFoundation 0x31df5d49 CFRunLoopRunInMode + 104
20 GraphicsServices 0x359722eb GSEventRunModal + 74
21 UIKit 0x33d0b301 UIApplicationMain + 1120
22 --------------- 0x00116833 main (main.m:16)
23 libdyld.dylib 0x39f42b20 start

Related

UIView(AdditionalLayoutSupport) _switchToLayoutEngine Xcode Crash

I'm dealing with a weird crash which I didn't find a solution yet for.
The title of the crash in Organizer is UIKit: __57-[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:]_block_invoke_2 + 316 and the whole stacktrace is below.
I've checked the startController(_:) method from AppDelegate and everything seems to be fine. Is it a constraint issue maybe? What else could it be?
Last Exception Backtrace:
0 CoreFoundation 0x1d57bb38 __exceptionPreprocess + 124 (NSException.m:165)
1 libobjc.A.dylib 0x1c803062 objc_exception_throw + 34 (objc-exception.mm:521)
2 CoreFoundation 0x1d580fcc -[NSObject(NSObject) doesNotRecognizeSelector:] + 118 (NSObject.m:328)
3 CoreFoundation 0x1d57f0be ___forwarding___ + 692 (NSForwarding.m:3126)
4 CoreFoundation 0x1d4a7dc4 _CF_forwarding_prep_0 + 20
5 Foundation 0x1ded2b76 -[NSLayoutAnchor nsli_lowerIntoExpression:withCoefficient:forConstraint:] + 498 (NSLayoutAnchor.m:883)
6 Foundation 0x1de1b142 -[NSLayoutConstraint _lowerIntoExpression:reportingConstantIsRounded:] + 104 (NSLayoutConstraint.m:1723)
7 Foundation 0x1de1addc -[NSLayoutConstraint _addToEngine:integralizationAdjustment:mutuallyExclusiveConstraints:] + 120 (NSLayoutConstraint.m:1606)
8 Foundation 0x1de265b4 -[NSLayoutConstraint _addToEngine:] + 24 (NSLayoutConstraint.m:1621)
9 UIKit 0x228a88b2 __57-[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:]_block_invoke_2 + 316 (NSLayoutConstraint_UIKitAdditions.m:3596)
10 Foundation 0x1de1a97e -[NSISEngine withBehaviors:performModifications:] + 258 (NSISEngine.m:1973)
11 UIKit 0x228a873a __57-[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:]_block_invoke + 502 (NSLayoutConstraint_UIKitAdditions.m:3585)
12 UIKit 0x227aa5e8 -[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:] + 216 (NSLayoutConstraint_UIKitAdditions.m:3550)
13 UIKit 0x228e3654 -[UIView(AdditionalLayoutSupport) _initializeHostedLayoutEngine] + 486 (NSLayoutConstraint_UIKitAdditions.m:3333)
14 UIKit 0x228afe20 -[UIView(UIConstraintBasedLayout) _layoutEngine_windowDidChange] + 120 (NSLayoutConstraint_UIKitAdditions.m:563)
15 UIKit 0x227aa6e0 -[UIView(Internal) _didMoveFromWindow:toWindow:] + 208 (UIView.m:12461)
16 UIKit 0x227a9ee0 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 120 (UIView.m:9478)
17 UIKit 0x227a9d6c -[UIView(Hierarchy) _postMovedFromSuperview:] + 710 (UIView.m:361)
18 UIKit 0x227b527a -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1636 (UIView.m:13256)
19 UIKit 0x227b4bfe -[UIView(Hierarchy) addSubview:] + 726 (UIView.m:9004)
20 UIKit 0x227b420c -[UIWindow addRootViewControllerViewIfPossible] + 506 (UIWindow.m:1498)
21 UIKit 0x227b15b6 -[UIWindow _setHidden:forced:] + 282 (UIWindow.m:1572)
22 UIKit 0x22821154 -[UIWindow makeKeyAndVisible] + 38 (UIWindow.m:4934)
23 MyApp 0x1c3f28 AppDelegate.startController(_:) + 978 (AppDelegate.swift:207)
24 MyApp 0x1cad3c specialized AppDelegate.application(_:didFinishLaunchingWithOptions:) + 3082 (AppDelegate.swift:141)
25 MyApp 0x1c3a18 #objc AppDelegate.application(_:didFinishLaunchingWithOptions:) + 152 (<compiler-generated>:0)
26 UIKit 0x2281d5c0 -[UIApplication _handleDelegateCallbacksWithOptions:isSuspended:restoreState:] + 372 (UIApplication.m:1797)
27 UIKit 0x22a1ea46 -[UIApplication _callInitializationDelegatesForMainScene:transitionContext:] + 3702 (UIApplication.m:2129)
28 UIKit 0x22a23c18 -[UIApplication _runWithMainScene:transitionContext:completion:] + 1636 (UIApplication.m:3625)
29 UIKit 0x22a367c0 __84-[UIApplication _handleApplicationActivationWithScene:transitionContext:completion:]_block_invoke.3149 + 36 (UIApplication.m:10365)
30 UIKit 0x22a21356 -[UIApplication workspaceDidEndTransaction:] + 138 (UIApplication.m:2989)
31 FrontBoardServices 0x1ee5cc0e __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 14 (FBSSerialQueue.m:158)
32 FrontBoardServices 0x1ee5cac8 -[FBSSerialQueue _performNext] + 216 (FBSSerialQueue.m:177)
33 FrontBoardServices 0x1ee5cdb2 -[FBSSerialQueue _performNextFromRunLoopSource] + 40 (FBSSerialQueue.m:206)
34 CoreFoundation 0x1d537fd8 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 8 (CFRunLoop.c:1941)
35 CoreFoundation 0x1d537b00 __CFRunLoopDoSources0 + 420 (CFRunLoop.c:1989)
36 CoreFoundation 0x1d535f4c __CFRunLoopRun + 1156 (CFRunLoop.c:2821)
37 CoreFoundation 0x1d4891aa CFRunLoopRunSpecific + 466 (CFRunLoop.c:3113)
38 CoreFoundation 0x1d488fcc CFRunLoopRunInMode + 100 (CFRunLoop.c:3143)
39 UIKit 0x22816e28 -[UIApplication _run] + 656 (UIApplication.m:2658)
40 UIKit 0x22811a4e UIApplicationMain + 146 (UIApplication.m:4089)
41 MyApp 0x68564 main + 32 (HighlightsDetailViewController.swift:62)
42 libdyld.dylib 0x1cc764e6 _dyld_process_info_notify_release + 26 (dyld_process_info_notify.cpp:327)
Thanks in advance!
I finally solved the problem. Shortly, the crash appeared only on iOS 10.x devices, because some of my .xib files had had set a later version of iOS (11.0 i.e.) in "File Inspector -> Interface Builder Document -> Builds for" instead of the default Deployment Target set in the project settings, which was 10.x of course.

iOS random crash because of memory corruption

My app has many random crashes recently. Fabric shows the crash rate is about 1%. The crash session number and the crash user number is very close, which means it's very random.
The crash shows several different callstacks on Fabric, here are three of them.
==========1===============
#0. Crashed: com.apple.main-thread
0 QuartzCore 0x188715730 CALayerGetSuperlayer + 20
1 UIKit 0x188dd6fa0 -[UIView(Hierarchy) superview] + 44
2 UIKit 0x188dd7a88 -[UIView nextResponder] + 108
3 UIKit 0x188e9d99c -[UIResponder _containsResponder:] + 56
4 UIKit 0x188ecfc80 -[UITransitionView transition:fromView:toView:removeFromView:] + 576
5 UIKit 0x188f13238 -[UITabBarController transitionFromViewController:toViewController:transition:shouldSetSelected:] + 1536
6 UIKit 0x188f12aec -[UITabBarController _setSelectedViewController:] + 360
7 UIKit 0x188fda30c -[UITabBarController _tabBarItemClicked:] + 336
8 UIKit 0x188e11398 -[UIApplication sendAction:to:from:forEvent:] + 96
9 UIKit 0x188fda160 -[UITabBar _sendAction:withEvent:] + 468
10 UIKit 0x188e11398 -[UIApplication sendAction:to:from:forEvent:] + 96
11 UIKit 0x188dfa474 -[UIControl _sendActionsForEvents:withEvent:] + 612
12 UIKit 0x188fd9d98 -[UITabBar(Static) _buttonUp:] + 128
13 UIKit 0x188e11398 -[UIApplication sendAction:to:from:forEvent:] + 96
14 UIKit 0x188dfa474 -[UIControl _sendActionsForEvents:withEvent:] + 612
15 UIKit 0x188e10d34 -[UIControl touchesEnded:withEvent:] + 592
16 UIKit 0x188dcff54 _UIGestureRecognizerUpdate + 8536
17 CoreFoundation 0x18431c2a4 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
18 CoreFoundation 0x184319230 __CFRunLoopDoObservers + 360
19 CoreFoundation 0x184319610 __CFRunLoopRun + 836
20 CoreFoundation 0x1842452d4 CFRunLoopRunSpecific + 396
21 GraphicsServices 0x18dc9b6fc GSEventRunModal + 168
22 UIKit 0x188e42f40 UIApplicationMain + 1488
======================2=======================
#0. Crashed: com.apple.main-thread
0 QuartzCore 0x18e7ca1d0 CALayerGetSuperlayer + 20
1 UIKit 0x191e4e9d4 -[UIView(UIKitManual) superview] + 128
2 UIKit 0x1915d3a5c -[UIView nextResponder] + 120
3 UIKit 0x19197d620 -[UIResponder _canChangeFirstResponder:toResponder:] + 64
4 UIKit 0x19165c01c -[UIResponder becomeFirstResponder] + 224
5 UIKit 0x19169b118 -[UINavigationController navigationTransitionView:didStartTransition:] + 760
6 UIKit 0x1917758ac -[UINavigationController _startCustomTransition:] + 3852
7 UIKit 0x19168f7bc -[UINavigationController _startDeferredTransitionIfNeeded:] + 676
8 UIKit 0x19168f424 -[UINavigationController __viewWillLayoutSubviews] + 64
9 UIKit 0x19168f388 -[UILayoutContainerView layoutSubviews] + 188
10 UIKit 0x1915d5cc0 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1200
11 QuartzCore 0x18e7c6274 -[CALayer layoutSublayers] + 148
12 QuartzCore 0x18e7bade8 CA::Layer::layout_if_needed(CA::Transaction*) + 292
13 QuartzCore 0x18e7baca8 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 32
14 QuartzCore 0x18e73634c CA::Context::commit_transaction(CA::Transaction*) + 252
15 QuartzCore 0x18e75d3ac CA::Transaction::commit() + 504
16 QuartzCore 0x18e75de78 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) + 120
17 CoreFoundation 0x18b4549a8 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
18 CoreFoundation 0x18b452630 __CFRunLoopDoObservers + 372
19 CoreFoundation 0x18b452a7c __CFRunLoopRun + 956
20 CoreFoundation 0x18b382da4 CFRunLoopRunSpecific + 424
21 GraphicsServices 0x18cded074 GSEventRunModal + 100
22 UIKit 0x19163dc9c UIApplicationMain + 208
=========3========
#0. Crashed: com.apple.main-thread
0 libobjc.A.dylib 0x18fe4c1a0 objc_retain + 16
1 UIKit 0x1974fba5c -[UIView nextResponder] + 120
2 UIKit 0x1978a45ec -[UIResponder _resignIfContainsFirstResponder] + 156
3 UIKit 0x1974fb76c -[UIView(Hierarchy) _willMoveToWindow:] + 568
4 UIKit 0x197507d88 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 424
5 UIKit 0x197773000 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke_2 + 1556
6 UIKit 0x19750e964 +[UIView(Animation) performWithoutAnimation:] + 104
7 UIKit 0x1976e0950 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke + 260
8 UIKit 0x1977fd388 +[UIView(Internal) _performBlockDelayingTriggeringResponderEvents:] + 220
9 UIKit 0x1976e0450 -[_UINavigationParallaxTransition animateTransition:] + 1060
10 UIKit 0x19769d818 -[UINavigationController _startCustomTransition:] + 3704
11 UIKit 0x1975b77bc -[UINavigationController _startDeferredTransitionIfNeeded:] + 676
12 UIKit 0x1975b7424 -[UINavigationController __viewWillLayoutSubviews] + 64
13 UIKit 0x1975b7388 -[UILayoutContainerView layoutSubviews] + 188
14 UIKit 0x1974fdcc0 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1200
15 QuartzCore 0x1946ee274 -[CALayer layoutSublayers] + 148
16 QuartzCore 0x1946e2de8 CA::Layer::layout_if_needed(CA::Transaction*) + 292
17 QuartzCore 0x1946e2ca8 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 32
18 QuartzCore 0x19465e34c CA::Context::commit_transaction(CA::Transaction*) + 252
19 QuartzCore 0x1946853ac CA::Transaction::commit() + 504
20 UIKit 0x1974f3308 _afterCACommitHandler + 256
21 CoreFoundation 0x19137c9a8 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
22 CoreFoundation 0x19137a630 __CFRunLoopDoObservers + 372
23 CoreFoundation 0x19137aa7c __CFRunLoopRun + 956
24 CoreFoundation 0x1912aada4 CFRunLoopRunSpecific + 424
25 GraphicsServices 0x192d15074 GSEventRunModal + 100
26 UIKit 0x197565c9c UIApplicationMain + 208
I have no idea which page or what action caused this crash, and I can't reproduce this either.
Also tried Xcode analytics, zombie, memory instrument, with no luck.
Please let me know if you have any comments.

SIGSEGV SEGV_MAPERR crash, only iOS 9.2.1

my app crash only iOS 9.2.1
The rest of devices okay. Crash in arbitrary places. Please help me =) I use crittercism. I am new to programming, tell me the right way please. Name SIGSEGV Reason SEGV_MAPERR
0 libobjc.A.dylib 0x0000000180d09bdc objc_msgSend + 24
1 UIKit 0x000000018696a654 -[UINibStringIDTable lookupKey:identifier:] + 128
2 UIKit 0x000000018696614c -[UINibDecoder containsValueForKey:] + 44
3 UIKit 0x0000000186698a8c -[UIScrollView initWithCoder:] + 1396
4 UIKit 0x0000000186b99b00 -[UICollectionView initWithCoder:] + 72
5 UIKit 0x000000018696667c UINibDecoderDecodeObjectForValue + 668
6 UIKit 0x00000001869663c4 -[UINibDecoder decodeObjectForKey:] + 332
7 UIKit 0x000000018684615c -[UIRuntimeConnection initWithCoder:] + 184
8 UIKit 0x000000018696667c UINibDecoderDecodeObjectForValue + 668
9 UIKit 0x00000001869667f4 UINibDecoderDecodeObjectForValue + 1044
10 UIKit 0x00000001869663c4 -[UINibDecoder decodeObjectForKey:] + 332
11 UIKit 0x0000000186845490 -[UINib instantiateWithOwner:options:] + 1216
12 UIKit 0x00000001866ef33c -[UIViewController _loadViewFromNibNamed:bundle:] + 372
13 UIKit 0x00000001864b8250 -[UIViewController loadView] + 172
14 UIKit 0x000000018637bd6c -[UIViewController loadViewIfRequired] + 140
15 UIKit 0x000000018643bda8 -[UINavigationController _layoutViewController:] + 68
16 UIKit 0x000000018643bc80 -[UINavigationController _updateScrollViewFromViewController:toViewController:] + 412
17 UIKit 0x000000018643aec8 -[UINavigationController _startTransition:fromViewController:toViewController:] + 140
18 UIKit 0x000000018643aa6c -[UINavigationController _startDeferredTransitionIfNeeded:] + 864
19 UIKit 0x000000018643a694 -[UINavigationController __viewWillLayoutSubviews] + 56
20 UIKit 0x000000018643a5fc -[UILayoutContainerView layoutSubviews] + 204
21 UIKit 0x0000000186377778 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 652
22 QuartzCore 0x0000000183d86b2c -[CALayer layoutSublayers] + 144
23 QuartzCore 0x0000000183d81738 CA::Layer::layout_if_needed() + 288
24 QuartzCore 0x0000000183d815f8 CA::Layer::layout_and_display_if_needed() + 28
25 QuartzCore 0x0000000183d80c94 CA::Context::commit_transaction() + 248
26 QuartzCore 0x0000000183d809dc CA::Transaction::commit() + 508
27 QuartzCore 0x0000000183d7a0cc CA::Transaction::observer_callback() + 76
28 CoreFoundation 0x0000000181640588 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 28
29 CoreFoundation 0x000000018163e32c __CFRunLoopDoObservers + 368
30 CoreFoundation 0x000000018163e75c __CFRunLoopRun + 924
31 CoreFoundation 0x000000018156d680 CFRunLoopRunSpecific + 380
32 GraphicsServices 0x0000000182a7c088 GSEventRunModal + 176
33 UIKit 0x00000001863e4d90 UIApplicationMain + 200
! 34 keep-app 0x0000000100060350 main (main.m:14)
35 libdyld.dylib 0x000000018110e8b8 start + 0
Name SIGSEGV Reason SEGV_MAPERR
0 libobjc.A.dylib 0x0000000180d09bdc objc_msgSend + 24
1 libcache.dylib 0x0000000181062b5c _entry_get_optionally_checking_collisions + 48
2 libcache.dylib 0x0000000181060dd0 _entry_table_resize + 304
3 libcache.dylib 0x0000000181061a9c cache_set_and_retain + 848
4 CoreFoundation 0x00000001815bb470 -[NSCache setObject:forKey:cost:] + 264
5 CoreUI 0x00000001861a2854 -[CUIStructuredThemeStore _canGetRenditionWithKey:isFPO:lookForSubstitutions:] + 856
6 CoreUI 0x00000001861c4d5c -[CUICatalog _resolvedRenditionKeyFromThemeRef:withBaseKey:scaleFactor:deviceIdiom:deviceSubtype:sizeClassHorizontal:sizeClassVertical:memoryClass:graphicsClass:graphicsFallBackOrder:] + 920
7 CoreUI 0x00000001861c40fc -[CUICatalog namedLookupWithName:scaleFactor:deviceIdiom:deviceSubtype:sizeClassHorizontal:sizeClassVertical:] + 144
8 UIKit 0x0000000186bd9994 __98-[_UIAssetManager imageNamed:scale:idiom:subtype:cachingOptions:sizeClassPair:attachCatalogImage:]_block_invoke + 420
9 UIKit 0x0000000186bd9734 -[_UIAssetManager imageNamed:scale:idiom:subtype:cachingOptions:sizeClassPair:attachCatalogImage:] + 208
10 UIKit 0x0000000186bd9f18 -[_UIAssetManager imageNamed:withTrait:] + 524
11 UIKit 0x0000000186773c5c _UIImageWithNameAndTraitCollection + 92
12 UIKit 0x0000000186396220 _UIImageWithName + 44
13 UIKit 0x00000001865d7650 -[UISlider createThumbViewNeue] + 160
14 UIKit 0x00000001865d6dec -[UISlider _initSubviews] + 68
15 UIKit 0x00000001865d69c8 -[UISlider layoutSubviews] + 136
16 UIKit 0x0000000186377778 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 652
17 QuartzCore 0x0000000183d86b2c -[CALayer layoutSublayers] + 144
18 QuartzCore 0x0000000183d81738 CA::Layer::layout_if_needed() + 288
19 UIKit 0x000000018638e454 -[UIView(Hierarchy) layoutBelowIfNeeded] + 920
20 UIKit 0x000000018643c20c -[UINavigationController _layoutViewController:] + 1192
21 UIKit 0x0000000186439be4 -[UINavigationController _layoutTopViewController] + 224
22 UIKit 0x00000001864527dc -[UINavigationController navigationTransitionView:didEndTransition:fromView:toView:] + 724
23 UIKit 0x00000001864524c8 -[UINavigationTransitionView _notifyDelegateTransitionDidStopWithContext:] + 412
24 UIKit 0x00000001864521d0 -[UINavigationTransitionView _cleanupTransition] + 740
25 UIKit 0x00000001863b6e90 -[UIViewAnimationState sendDelegateAnimationDidStop:finished:] + 308
26 UIKit 0x00000001863b510c +[UIViewAnimationState popAnimationState] + 320
27 UIKit 0x0000000186445cec -[UINavigationTransitionView transition:fromView:toView:] + 1788
28 UIKit 0x000000018643b8c0 -[UINavigationController _startTransition:fromViewController:toViewController:] + 2692
29 UIKit 0x000000018643aa6c -[UINavigationController _startDeferredTransitionIfNeeded:] + 864
30 UIKit 0x000000018643a694 -[UINavigationController __viewWillLayoutSubviews] + 56
31 UIKit 0x000000018643a5fc -[UILayoutContainerView layoutSubviews] + 204
32 UIKit 0x0000000186377778 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 652
33 QuartzCore 0x0000000183d86b2c -[CALayer layoutSublayers] + 144
34 QuartzCore 0x0000000183d81738 CA::Layer::layout_if_needed() + 288
35 QuartzCore 0x0000000183d815f8 CA::Layer::layout_and_display_if_needed() + 28
36 QuartzCore 0x0000000183d80c94 CA::Context::commit_transaction() + 248
37 QuartzCore 0x0000000183d809dc CA::Transaction::commit() + 508
38 QuartzCore 0x0000000183d7a0cc CA::Transaction::observer_callback() + 76
39 CoreFoundation 0x0000000181640588 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 28
40 CoreFoundation 0x000000018163e32c __CFRunLoopDoObservers + 368
41 CoreFoundation 0x000000018163e75c __CFRunLoopRun + 924
42 CoreFoundation 0x000000018156d680 CFRunLoopRunSpecific + 380
43 GraphicsServices 0x0000000182a7c088 GSEventRunModal + 176
44 UIKit 0x00000001863e4d90 UIApplicationMain + 200
! 45 keep-app 0x00000001000b4350 main (main.m:14)
46 libdyld.dylib 0x000000018110e8b8 start + 0
Name SIGSEGV Reason SEGV_MAPERR
0 libsystem_malloc.dylib 0x0000000181257be8 szone_free + 2940
1 CoreFoundation 0x00000001815699a4 CFRelease + 1084
2 CoreUI 0x00000001861a240c -[CUIStructuredThemeStore renditionWithKey:usingKeySignature:] + 1596
3 CoreUI 0x00000001861c435c -[CUICatalog _storageRefForRendition:representsODRContent:] + 100
4 CoreUI 0x00000001861c4124 -[CUICatalog namedLookupWithName:scaleFactor:deviceIdiom:deviceSubtype:sizeClassHorizontal:sizeClassVertical:] + 184
5 UIKit 0x0000000186bd9994 __98-[_UIAssetManager imageNamed:scale:idiom:subtype:cachingOptions:sizeClassPair:attachCatalogImage:]_block_invoke + 420
6 UIKit 0x0000000186bd9734 -[_UIAssetManager imageNamed:scale:idiom:subtype:cachingOptions:sizeClassPair:attachCatalogImage:] + 208
7 UIKit 0x0000000186cec584 -[UIImageAsset imageWithTraitCollection:] + 400
8 UIKit 0x000000018672b058 -[UIImageView _resolveImageForTrait:] + 456
9 UIKit 0x000000018672a928 -[UIImageView _didMoveFromWindow:toWindow:] + 208
10 UIKit 0x0000000186376d7c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 756
11 UIKit 0x0000000186376310 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 148
12 Foundation 0x0000000181fa9500 -[NSISEngine withBehaviors:performModifications:] + 164
13 UIKit 0x0000000186376194 -[UIView(Hierarchy) _postMovedFromSuperview:] + 528
14 UIKit 0x0000000186383b80 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1780
15 UIKit 0x0000000186575600 -[_UIParallaxDimmingView didMoveToWindow] + 176
16 UIKit 0x000000018637705c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 1492
17 UIKit 0x0000000186376d7c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 756
18 UIKit 0x0000000186376310 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 148
19 Foundation 0x0000000181fa9500 -[NSISEngine withBehaviors:performModifications:] + 164
20 UIKit 0x0000000186376194 -[UIView(Hierarchy) _postMovedFromSuperview:] + 528
21 UIKit 0x0000000186383b80 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1780
22 UIKit 0x0000000186615db4 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke_2 + 1652
23 UIKit 0x000000018638a964 +[UIView(Animation) performWithoutAnimation:] + 76
24 UIKit 0x0000000186575118 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke + 256
25 UIKit 0x0000000186690840 +[UIView(Internal) _performBlockDelayingTriggeringResponderEvents:] + 216
26 UIKit 0x0000000186574c90 -[_UINavigationParallaxTransition animateTransition:] + 1056
27 UIKit 0x000000018652e6a0 -[UINavigationController _startCustomTransition:] + 3540
28 UIKit 0x000000018643a9b8 -[UINavigationController _startDeferredTransitionIfNeeded:] + 684
29 UIKit 0x000000018643a694 -[UINavigationController __viewWillLayoutSubviews] + 56
30 UIKit 0x000000018643a5fc -[UILayoutContainerView layoutSubviews] + 204
31 UIKit 0x0000000186377778 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 652
32 QuartzCore 0x0000000183d86b2c -[CALayer layoutSublayers] + 144
33 QuartzCore 0x0000000183d81738 CA::Layer::layout_if_needed() + 288
34 QuartzCore 0x0000000183d815f8 CA::Layer::layout_and_display_if_needed() + 28
35 QuartzCore 0x0000000183d80c94 CA::Context::commit_transaction() + 248
36 QuartzCore 0x0000000183d809dc CA::Transaction::commit() + 508
37 QuartzCore 0x0000000183d7a0cc CA::Transaction::observer_callback() + 76
38 CoreFoundation 0x0000000181640588 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 28
39 CoreFoundation 0x000000018163e32c __CFRunLoopDoObservers + 368
40 CoreFoundation 0x000000018163e75c __CFRunLoopRun + 924
41 CoreFoundation 0x000000018156d680 CFRunLoopRunSpecific + 380
42 GraphicsServices 0x0000000182a7c088 GSEventRunModal + 176
43 UIKit 0x00000001863e4d90 UIApplicationMain + 200
! 44 keep-app 0x00000001000c0350 main (main.m:14)
45 libdyld.dylib 0x000000018110e8b8 start + 0
Unfortunately I do not have access to this device iOS 9.2.1. in the simulator and my device is working fine iOS 10.2
A SIGSEGV is an error / signal caused by an invalid memory reference or a segmentation fault. Seems like the app is trying to access an array element out of bounds or trying to use too much memory.
The way to fix this issue is to find out what the exception may be by making it happen on another device (or simulator), or getting the full console logs from that device. An easy way to do this might be to set exception breakpoints to see where the original exception that triggered the SIGSEGV is located.

How to detect crash from the following code?

Im trying to find crash from following code / snippet.
Thread : Crashed: com.apple.main-thread
0 libobjc.A.dylib 6771342288 objc_msgSend + 16
1 Foundation 6488040888 vars_index_with_insert + 396
2 Foundation 6488046624 -[NSISLinearExpression setCoefficient:forVariable:] + 372
3 Foundation 6488038164 -[NSLayoutConstraint _lowerIntoExpression:reportingConstantIsRounded:] + 432
4 Foundation 6488033112 -[NSLayoutConstraint _tryToChangeContainerGeometryWithUndoHandler:] + 136
5 Foundation 6488032176 -[NSLayoutConstraint _setSymbolicConstant:constant:] + 420
6 UIKit 6558145124 -[UIWindow(AdditionalLayoutSupport) _windowInternalConstraints_sizeDidChange] + 220
7 UIKit 6553937808 -[UIWindow _setFrame:sendTraitNotifications:] + 436
8 UIKit 6553925712 __78-[UIWindow _rotateWindowToOrientation:updateStatusBar:duration:skipCallbacks:]_block_invoke1072 + 264
9 UIKit 6556461676 __58-[_UIWindowRotationAnimationController animateTransition:]_block_invoke + 56
10 UIKit 6551262980 +[UIView(UIViewAnimationWithBlocks) _setupAnimationWithDuration:delay:view:options:factory:animations:start:animationStateGenerator:completion:] + 508
11 UIKit 6551360196 +[UIView(UIViewAnimationWithBlocks) animateWithDuration:delay:options:animations:completion:] + 68
12 UIKit 6556461540 -[_UIWindowRotationAnimationController animateTransition:] + 388
13 UIKit 6553920912 -[UIWindow _rotateToBounds:withAnimator:transitionContext:] + 800
14 UIKit 6553924620 -[UIWindow _rotateWindowToOrientation:updateStatusBar:duration:skipCallbacks:] + 1260
15 UIKit 6553926412 -[UIWindow _setRotatableClient:toOrientation:applyTransformToWindow:updateStatusBar:duration:force:isRotating:] + 360
16 UIKit 6551563312 -[UIWindow _setRotatableViewOrientation:updateStatusBar:duration:force:] + 144
17 UIKit 6551529112 __57-[UIWindow _updateToInterfaceOrientation:duration:force:]_block_invoke + 128
18 UIKit 6551053184 -[UIWindow _updateToInterfaceOrientation:duration:force:] + 400
19 UIKit 6551051872 -[UIWindow _updateInterfaceOrientationFromDeviceOrientation:] + 332
20 CoreFoundation 6472590020 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20
21 CoreFoundation 6471791696 _CFXNotificationPost + 2060
22 Foundation 6487714432 -[NSNotificationCenter postNotificationName:object:userInfo:] + 72
23 UIKit 6551051060 -[UIDevice setOrientation:animated:] + 360
24 UIKit 6551050224 -[UIApplication handleEvent:withNewEvent:] + 1632
25 UIKit 6551048320 -[UIApplication sendEvent:] + 104
26 UIKit 6551491268 _UIApplicationHandleEvent + 700
27 GraphicsServices 6633656724 _PurpleEventCallback + 712
28 GraphicsServices 6633655428 PurpleEventCallback + 44
29 CoreFoundation 6472661588 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56
30 CoreFoundation 6472661428 __CFRunLoopDoSource1 + 436
31 CoreFoundation 6472653108 __CFRunLoopRun + 1640
32 CoreFoundation 6471783124 CFRunLoopRunSpecific + 396
33 GraphicsServices 6633649916 GSEventRunModal + 168
34 UIKit 6551465792 UIApplicationMain + 1488
35 project_name 4298267384 main + 108 (main.m:18)
36 libdyld.dylib 6778251784 start + 4
go to "Breakpoint navigator" and click on "+" button on bottom-left and select "Add Exception Breakpoint...".
This kind of breakpoint capture all exception, so you can navigate on stack error on left side and figure out what happened.

iOS 6 crashing with iAD

This app was released sevearl months ago and worked perfectly in iOS 4/5. Now getting crashes in some screens in iOS 6.
Fairly easy implementation. Have an AdBannerView in a xib. I wired it to the delagate. Have my delagate methods showing/hiding the ads. Here's the crash data.
Exception Type: EXC_CRASH (SIGABRT)
Last Exception Backtrace:
0 CoreFoundation 0x36d9b29e __exceptionPreprocess + 158
1 libobjc.A.dylib 0x350ab97a objc_exception_throw + 26
2 CoreFoundation 0x36cec55a -[__NSPlaceholderDictionary initWithObjects:forKeys:count:] + 130
3 CoreFoundation 0x36d230ce +[NSDictionary dictionaryWithObjects:forKeys:count:] + 46
4 iAd 0x3594c23e -[ADBannerView setDelegate:] + 126
5 Foundation 0x347b49cc -[NSObject(NSKeyValueCoding) setValue:forKey:] + 208
6 UIKit 0x382101dc -[UIView(CALayerDelegate) setValue:forKey:] + 156
7 Foundation 0x347b071e -[NSObject(NSKeyValueCoding) setValue:forKeyPath:] + 294
8 CoreFoundation 0x36d21616 -[NSArray makeObjectsPerformSelector:] + 174
9 UIKit 0x38209240 -[UINib instantiateWithOwner:options:] + 1036
10 UIKit 0x38208abe -[UIViewController _loadViewFromNibNamed:bundle:] + 230
11 UIKit 0x38101020 -[UIViewController loadView] + 88
12 UIKit 0x3808b468 -[UIViewController loadViewIfRequired] + 64
13 UIKit 0x380e0136 -[UIViewController contentScrollView] + 22
14 UIKit 0x380e007c -[UINavigationController _computeAndApplyScrollContentInsetDeltaForViewController:] + 24
15 UIKit 0x380dff60 -[UINavigationController _layoutViewController:] + 28
16 UIKit 0x380dfe84 -[UINavigationController _updateScrollViewFromViewController:toViewController:] + 268
17 UIKit 0x380df5c4 -[UINavigationController _startTransition:fromViewController:toViewController:] + 60
18 UIKit 0x380df4ac -[UINavigationController _startDeferredTransitionIfNeeded:] + 320
19 UIKit 0x380cdb8e -[UINavigationController pushViewController:transition:forceImmediate:] + 854
20 UIKit 0x380cd82e -[UINavigationController pushViewController:animated:] + 34
21 Hurricane 0x00002d9a -[TrackerViewController buttonPressed:] (TrackerViewController.m:111)
22 UIKit 0x381570a8 -[UIApplication sendAction:to:from:forEvent:] + 68
23 UIKit 0x3815705a -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 26
24 UIKit 0x38157038 -[UIControl sendAction:to:forEvent:] + 40
25 UIKit 0x381568ee -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 498
26 UIKit 0x38156de4 -[UIControl touchesEnded:withEvent:] + 484
27 UIKit 0x3807f5f4 -[UIWindow _sendTouchesForEvent:] + 520
28 UIKit 0x3806c804 -[UIApplication sendEvent:] + 376
29 UIKit 0x3806c11e _UIApplicationHandleEvent + 6150
30 GraphicsServices 0x3721f59e _PurpleEventCallback + 586
31 GraphicsServices 0x3721f1ce PurpleEventCallback + 30
32 CoreFoundation 0x36d7016e __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 30
33 CoreFoundation 0x36d70112 __CFRunLoopDoSource1 + 134
34 CoreFoundation 0x36d6ef94 __CFRunLoopRun + 1380
35 CoreFoundation 0x36ce1eb8 CFRunLoopRunSpecific + 352
36 CoreFoundation 0x36ce1d44 CFRunLoopRunInMode + 100
37 GraphicsServices 0x3721e2e6 GSEventRunModal + 70
38 UIKit 0x380c02fc UIApplicationMain + 1116
39 Hurricane 0x00002082 main (main.m:14)
40 Hurricane 0x0000203c start + 36
If I unwire the AdBannerView it works. Rewire and crash. I don't have any dictioniaries in this particular controller. In fact, it only has 6 buttons leading to other screens. The real strange thing is that the code is used elsewhere in other screens which work fine. Obviously, it worked fine before.
Let me clear you, In iOS 6, there are some properties and methods deprecated for AdBannerView . i think this should be the reason of your crash.
Please check this
http://developer.apple.com/library/ios/DOCUMENTATION/UserExperience/Reference/ADBannerView_Ref/Reference/Reference.html#//apple_ref/doc/uid/TP40009562-CH1-DontLinkElementID_9

Resources