Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Crash on -[MGLMapView updateFromDisplayLink] #13824

Closed

Description

@marcelofabri
SIGABRT ABORT 0x00000001814382e8

Crashed: com.apple.main-thread
0  libsystem_kernel.dylib         0x1814382e8 __pthread_kill + 8
1  libsystem_pthread.dylib        0x18154d2f8 pthread_kill$VARIANT$mp + 396
2  libsystem_c.dylib              0x1813a6fbc abort + 140
3  Metal                          0x183649a9c MTLGetWarningMode + 270
4  AppleMetalGLRenderer           0x1a0f7af18 GLDTextureRec::allocMetalTexture()
5  AppleMetalGLRenderer           0x1a0f7b010 GLDTextureRec::loadPrivateTexture(unsigned int, unsigned short*)
6  AppleMetalGLRenderer           0x1a0f7917c GLDTextureRec::update(unsigned int, unsigned short*)
7  AppleMetalGLRenderer           0x1a0f75e98 GLDFramebufferRec::load()
8  AppleMetalGLRenderer           0x1a0f76224 gldLoadFramebuffer
9  GLEngine                       0x1a1d3e84c gleCheckFramebufferStatus
10 GLEngine                       0x1a1cebb44 glCheckFramebufferStatusEXT_Exec
11 GLKit                          0x18e72340c -[GLKView _createFramebuffer] + 1368
12 GLKit                          0x18e723660 -[GLKView _setFramebuffer:] + 132
13 GLKit                          0x18e7238ac -[GLKView _display:] + 88
14 Mapbox                         0x10785e77c -[MGLMapView updateFromDisplayLink] (MGLMapView.mm:1169)
15 QuartzCore                     0x185853710 CA::Display::DisplayLink::dispatch_items(unsigned long long, unsigned long long, unsigned long long) + 672
16 IOKit                          0x181b91098 IODispatchCalloutFromCFMessage + 392
17 CoreFoundation                 0x1818b4290 __CFMachPortPerform + 188
18 CoreFoundation                 0x1818cf000 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56
19 CoreFoundation                 0x1818ce704 __CFRunLoopDoSource1 + 440
20 CoreFoundation                 0x1818cc1d8 __CFRunLoopRun + 2196
21 CoreFoundation                 0x1817ebe58 CFRunLoopRunSpecific + 436
22 GraphicsServices               0x183698f84 GSEventRunModal + 100
23 UIKit                          0x18ae6b67c UIApplicationMain + 236
24 libswiftUIKit.dylib            0x108bb0da0 UIApplicationMain(_:_:_:_:) + 168
25 InstaShopper                   0x102a6a708 main (main.swift:5)
26 libdyld.dylib                  0x18130856c start + 4

Steps to reproduce

Not sure, reported by crash reporting. 0% in background. Firebase has thoughts about it:

Based on the stack trace displayed here, it looks like new calls triggering OpenGL rendering took place while the app was transitioning to, or from, a background state. If you set up OpenGL drawing in your app delegate's methods, make sure that you only did so in applicationDidBecomeActive:, never in application:willFinishLaunchingWithOptions: or application:didFinishLaunchingWithOptions:. According to some reports, even displaying an FPS indicator for SpriteKit could cause rendering to occur before it is allowed.

Expected behavior

No crash

Actual behavior

Crash

Configuration

Mapbox SDK versions: 4.7.0
iOS/macOS versions: iOS 11 and 12
Device/simulator models: all
Xcode version: 10.1

Activity

  1. added
    iOS
    on Jan 30, 2019
  2. julianrex commented on Jan 30, 2019

    @julianrex
    Contributor

    See also #13825 - call stack is very similar.

  3. julianrex commented on Jan 30, 2019

    @julianrex
    Contributor

    @marcelofabri do you know

    Do you have crash reports that list the available memory? Were there any memory warnings? At first glance these appear to be allocation related.

  4. marcelofabri commented on Jan 30, 2019

    @marcelofabri
    Author

    if these most recent issues you've added (#13820, #13823, #13824, #13825, #13826) are from the same device?

    There are several different users facing each crash. I imagine that they can overlap, but it doesn't seem to be a single device

    if user was attempting to AirPlay to an Apple TV?

    Seems very very unlikely given the nature of our app

    Do you have crash reports that list the available memory?

    Yeah, they range from ~25MB free memory to ~300MB in a few samples that I looked for this specific crash.

    We have a log for memory warnings on applicationDidReceiveMemoryWarning and it doesn't seem like we're getting it for the individual logs that I've looked into.

  5. hernangonzalez commented on Feb 19, 2019

    @hernangonzalez

    I am seeing this crash more often now.
    100% of the reports are in background.
    My reports are matched by the inclusion of Mapbox 4.8.0
    @julianrex @marcelofabri

  6. julianrex commented on Mar 6, 2019

    @julianrex
    Contributor

    @hernangonzalez thanks for the confirmation - what version of the SDK were you on before 4.8.0?

  7. hernangonzalez commented on Mar 6, 2019

    @hernangonzalez

    @julianrex I was on 4.7.1

  8. added
    archived
    on Sep 2, 2019
  9. stale commented on Sep 3, 2019

    @stale

    This issue has been automatically detected as stale because it has not had recent activity and will be archived. Thank you for your contributions.

  10. julianrex commented on Sep 3, 2019

    @julianrex
    Contributor

    This is not stale, improving backgrounding is still in the queue, but slipped because of some refactoring elsewhere.

  11. removed
    archived
    on Sep 3, 2019
  12. added
    archived
    on Mar 1, 2020
  13. stale commented on Mar 1, 2020

    @stale

    This issue has been automatically detected as stale because it has not had recent activity and will be archived. Thank you for your contributions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    archivedcrashiOS

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions