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.

[iOS] crash on MGLMapView updateFromDisplayLink #13372

Closed

Description

@RomainQuidet

Hi,
On our production app, the crash logs show that we have a lot of crashes from updateDisplayLink method.
We are trying to reproduce this bug manually with no success for the moment.
I'm not an openGL specialist, I don't get why this happens.

We see this crash more often on iPad than iPhone if this can help.

Here is the stack:

Date/Time: 2018-10-31T12:00:35Z
Launch Time: 2018-10-31T10:18:13Z
OS Version: iPhone OS 12.0.1 (16A404)
Report Version: 104

Exception Type: SIGSEGV
Exception Codes: SEGV_ACCERR at 0x1
Crashed Thread: 0

Thread 0 Crashed:
0 libGPUSupportMercury.dylib 0x00000001df9dcf48 gpus_ReturnGuiltyForHardwareRestart + 12
1 AGXGLDriver 0x00000001e418c8c0 gldUpdateDispatch + 7212
2 libGPUSupportMercury.dylib 0x00000001df9ddf04 gpusSubmitDataBuffers + 172
3 AGXGLDriver 0x00000001e418de08 gldUpdateDispatch + 12660
4 GLEngine 0x00000001e53e74e4 gliPresentViewES_Exec + 184
5 OpenGLES 0x00000001c5e8fa8c -[EAGLContext presentRenderbuffer:] + 76
6 GLKit 0x00000001cfd5292c -[GLKView _display:] + 304
7 Mapbox 0x0000000104242548 -[MGLMapView updateFromDisplayLink] (MGLMapView.mm:1126)
8 QuartzCore 0x00000001c7041574 CA::Display::DisplayLink::dispatch_items(unsigned long long, unsigned long long, unsigned long long) + 824
9 IOKit 0x00000001c2deb58c IODispatchCalloutFromCFMessage + 484
10 CoreFoundation 0x00000001c2af33e4 __CFMachPortPerform + 184
11 CoreFoundation 0x00000001c2b1ac30 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION + 52
12 CoreFoundation 0x00000001c2b1a37c __CFRunLoopDoSource1 + 436
13 CoreFoundation 0x00000001c2b15134 __CFRunLoopRun + 2136
14 CoreFoundation 0x00000001c2b145b8 CFRunLoopRunSpecific + 432
15 GraphicsServices 0x00000001c4d88584 GSEventRunModal + 96
16 UIKitCore 0x00000001ef990bc8 UIApplicationMain + 208
17 Mappy 0x00000001013dc054 main (main.m:7)
18 libdyld.dylib 0x00000001c25d4b94 start + 0

Configuration

Mapbox SDK versions: 4.4.1
**iOS/macOS versions: 11 & 12 **
Device/simulator models: devices
Xcode version: 10.1

Activity

  1. RomainQuidet commented on Nov 14, 2018

    @RomainQuidet
    ContributorAuthor

    Related: #1509

  2. julianrex commented on Nov 14, 2018

    @julianrex
    Contributor

    Thanks @RomainQuidet - the iPad tip is definitely interesting. Do you know if this is happening when going into the background? Can you tell anything else from the other threads in the crash log?

    #13293 is also on our radar and may (or may not) be related.

  3. RomainQuidet commented on Nov 15, 2018

    @RomainQuidet
    ContributorAuthor

    Hi,
    I can not say if our users are on background when this happens.
    Other threads don't seem to help:

    Thread 1:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   Foundation                           0x00000001c35086a4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 296
    5   libAXSpeechManager.dylib             0x00000001d2bf77b0 -[AXSpeechThread main] + 260
    6   Foundation                           0x00000001c363b3b0 __NSThread__start__ + 1036
    7   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    8   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    9   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 2:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   AVFAudio                             0x00000001c8aedc4c GenericRunLoopThread::Entry(void*) + 160
    5   AVFAudio                             0x00000001c8b19d34 CAPThread::Entry(CAPThread*) + 84
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 3:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   Foundation                           0x00000001c35086a4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 296
    5   Foundation                           0x00000001c3508550 -[NSRunLoop(NSRunLoop) runUntilDate:] + 144
    6   UIKitCore                            0x00000001efa7d41c -[UIEventFetcher threadMain] + 132
    7   Foundation                           0x00000001c363b3b0 __NSThread__start__ + 1036
    8   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    9   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    10  libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 4:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   CoreFoundation                       0x00000001c2b15354 CFRunLoopRun + 76
    5   Mapbox                               0x000000010448eff4 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::util::Thread<mbgl::AssetFileSource::Impl>::Thread<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&&&)::'lambda'()> >(void*, void*) (run_loop.cpp:37)
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 5:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   CoreFoundation                       0x00000001c2b15354 CFRunLoopRun + 76
    5   Mapbox                               0x0000000104492050 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::util::Thread<mbgl::DefaultFileSource::Impl>::Thread<std::__1::shared_ptr<mbgl::FileSource> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long long&>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<mbgl::FileSource> const&&&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&&&, unsigned long long&&&)::'lambda'()> >(void*, void*) (run_loop.cpp:37)
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 6:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   CoreFoundation                       0x00000001c2b15354 CFRunLoopRun + 76
    5   Mapbox                               0x0000000104497ee0 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::util::Thread<mbgl::LocalFileSource::Impl>::Thread<>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)::'lambda'()> >(void*, void*) (run_loop.cpp:37)
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 7:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   CoreFoundation                       0x00000001c2b15354 CFRunLoopRun + 76
    5   CoreMotion                           0x00000001c85432cc 0x1c84c7000 + 508620
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 8:
    0   libsystem_kernel.dylib               0x00000001c2720f0c __psynch_cvwait + 8
    1   libc++.1.dylib                       0x00000001c1cec4d0 std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 20
    2   Mapbox                               0x00000001042b36f8 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::ThreadPool::ThreadPool(unsigned long)::$_0> >(void*, void*) (__mutex_base:375)
    3   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    4   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    5   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 9:
    0   libsystem_kernel.dylib               0x00000001c2720f0c __psynch_cvwait + 8
    1   libc++.1.dylib                       0x00000001c1cec4d0 std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 20
    2   Mapbox                               0x00000001042b36f8 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::ThreadPool::ThreadPool(unsigned long)::$_0> >(void*, void*) (__mutex_base:375)
    3   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    4   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    5   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 10:
    0   libsystem_kernel.dylib               0x00000001c2720f0c __psynch_cvwait + 8
    1   libc++.1.dylib                       0x00000001c1cec4d0 std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 20
    2   Mapbox                               0x00000001042b36f8 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::ThreadPool::ThreadPool(unsigned long)::$_0> >(void*, void*) (__mutex_base:375)
    3   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    4   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    5   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 11:
    0   libsystem_kernel.dylib               0x00000001c2720f0c __psynch_cvwait + 8
    1   libc++.1.dylib                       0x00000001c1cec4d0 std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 20
    2   Mapbox                               0x00000001042b36f8 std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, mbgl::ThreadPool::ThreadPool(unsigned long)::$_0> >(void*, void*) (__mutex_base:375)
    3   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    4   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    5   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 12:
    0   libsystem_kernel.dylib               0x00000001c2715ed0 mach_msg_trap + 8
    1   CoreFoundation                       0x00000001c2b19fb0 __CFRunLoopServiceMachPort + 232
    2   CoreFoundation                       0x00000001c2b14e4c __CFRunLoopRun + 1392
    3   CoreFoundation                       0x00000001c2b145b8 CFRunLoopRunSpecific + 432
    4   CFNetwork                            0x00000001c3134e18 -[__CoreSchedulingSetRunnable runForever] + 208
    5   Foundation                           0x00000001c363b3b0 __NSThread__start__ + 1036
    6   libsystem_pthread.dylib              0x00000001c27a52fc _pthread_body + 124
    7   libsystem_pthread.dylib              0x00000001c27a525c _pthread_start + 44
    8   libsystem_pthread.dylib              0x00000001c27a8d08 thread_start + 0
    
    Thread 13:
    0   libsystem_kernel.dylib               0x00000001c2721b9c __workq_kernreturn + 8
    1   libsystem_pthread.dylib              0x00000001c27a8d00 start_wqthread + 0
    
    Thread 14:
    0   libsystem_pthread.dylib              0x00000001c27a8cfc start_wqthread + 0
    
    Thread 15:
    0   ???                                  0x0000000000000000 0x0 + 0
    
  4. added
    iOS
    on Nov 21, 2018
  5. added
    archived
    on May 20, 2019
  6. stale commented on May 20, 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.

  7. julianrex commented on May 20, 2019

    @julianrex
    Contributor

    This can stay closed - I believe it is a duplicate of #13293. @RomainQuidet please re-open if you continue to see issues. (There's a larger fix in the works).

  8. RomainQuidet commented on May 20, 2019

    @RomainQuidet
    ContributorAuthor
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

    archivediOS

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions