ipad - tips to track down intermittently freezing iOS UI -


i wrote huge ipad app 2 years ago , i'm getting , upgrading ios5. bit messy first large ipad app.

its has "sync" step may last several minutes , these bunch of asynchronous method calls go , fetch json url , put them core data. often, app freeze (ui unresponsive).

what techniques track down freezing? debugger isn't helpful unless code running on main thread, have no useable stack trace. app not recover either suggests sort of dead lock situation.

here 1 particular example might help:

enter image description here

i paused execution once verified frozen. seems freeze on same line every time - simple assignment. going on here? frustrating.

is core data access causing this? pointers appreciated.

edit 29-june-2012

click here see source of class create/update/deleting of core data objects. need stop freezing/crashing in app. know mess, makes me cringe too. wrote 2 years ago hardly knowledge of objective-c. should re-write have working , out of head in 2 days. give me pointers on approaches thread-safe quickly? wrap each method updates nsmanagedobjectcontext in grand central dispatch block code?

it indeed possible core data (in combination multithreading) cause of troubles - experienced similar problems.

here's excellent article on topic: core data , threads, without headache

i see call performselector: in stack trace. might want consider use grand central dispatch, although might lot rewrite in case.

as your actual question (tracking down deadlocks), i'd suggest using instruments well. also, @ status of other threads.


Comments

Popular posts from this blog

jquery - Invalid Assignment Left-Hand Side -

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -