Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS main thread freezes for few seconds

I am seeing main thread freezing for a few seconds in my app only on iOS 8 (not on previous iOS versions).
I am using @synchronised (self) at a number of places and also using RemoteIO setup. My question is how do I debug where exactly is the main thread blocking and get additional information, such as what it is doing at that time ?

I am using Xcode 6 so please tell me the best way to debug.

EDIT: Here is the output from Pause.

enter image description here

enter image description here

like image 213
Deepak Sharma Avatar asked Oct 06 '14 06:10

Deepak Sharma


1 Answers

As a first step to understand what's happening I would suggest to simply press Pause in debugger while you're having a freeze. It will show you which thread is doing what at that point.

You will either see a task that is still executing, or msg_trap row indicating that there's a lock somewhere.

Post here what you found out.

like image 57
hybridcattt Avatar answered Sep 20 '22 10:09

hybridcattt