我的应用程序随机崩溃。最终我发现当我添加 UIVIew 元素并修改它们的中心位置时会发生崩溃。IPad Air 2 上不会发生崩溃,但 IPad Air 上的情况是一致的 - 当 UIViews 打开时,会发生崩溃,并且当视图被移除时崩溃会消失。崩溃与以下堆栈异步发生:
#0 0x0000000190bf1f28 in gpus_ReturnGuiltyForHardwareRestart ()
#1 0x0000000190bf2ec4 in gpusSubmitDataBuffers ()
#2 0x0000000189d56254 in gliPresentViewES_Exec ()
#3 0x0000000189d5616c in gliPresentViewES ()
#4 0x0000000189d63cbc in -[EAGLContext presentRenderbuffer:] ()
#5 0x0000000101ff8078 in EAGLContext_presentRenderbuffer(EAGLContext*, objc_selector*, unsigned long) ()
#6 0x00000001877dc638 in -[GLKView _display:] ()
#7 0x000000018b55eeb8 in CA::Layer::display() ()
#8 0x000000018b5413a0 in CA::Layer::display_if_needed(CA::Transaction*) ()
#9 0x000000018b54108c in CA::Layer::layout_and_display_if_needed(CA::Transaction*) ()
#10 0x000000018b54071c in CA::Context::commit_transaction(CA::Transaction*) ()
#11 0x000000018b540470 in CA::Transaction::commit() ()
#12 0x000000018b539c10 in CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) ()
#13 0x000000018666f3f8 in __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ ()
#14 0x000000018666d19c in __CFRunLoopDoObservers ()
#15 0x000000018666d5cc in __CFRunLoopRun ()
#16 0x000000018659d280 in CFRunLoopRunSpecific ()
#17 0x00000001915500cc in GSEventRunModal ()
#18 0x000000018bd8adf8 in UIApplicationMain ()
#19 0x000000010077d36c in main at /Code/splinedr/Splinedr/main.mm:18
#20 0x000000019b7fa8b8 in start ()
[self.view needDisplay]
我在此之前使用调用和修改 UIView 来渲染 OpenGL 。
我应该如何处理这个问题?