I am testing out my app in terms of speed using the time profiler from Xcode Instrument. Below is the output. As I am new to this, I want to see if I can get a explanation to the output. This snapshot was taken before and after the transition ( I am looking to find out how to speed up the transition speed). My understanding is that it only took 24ms to transition to the new VC and the majority of the hard work was dispatched to a background thread. Is that correct?. It just appear to me that the transition was more than 24ms to me. It feels like 300~500ms (I can feel a delay after touchUpInside of a UIButton that initiated the transition). so I thought there might be more to reading this?
Asked
Active
Viewed 159 times
0
-
I suspect this 24ms is not elapsed time, but rather cpu time. Did your button routine do anything that could result in UI related tasks on a background thread? I'd expand those worker threads and make sure there's nothing there that should have been on the main thread. Also did you use the "record waiting threads" option? – Rob Sep 22 '16 at 08:36
-
Hi Rob, The dispatchWorkerThread3 would is not doing anything other than calculating the size of an image in kb and prints out to console for debugging purpose. How would I go about getting the elapsed time instead. I clicked on record waiting threads and it did not change much other than the time in ms becomes samples (241ms becomes 24 samples). – Sep 22 '16 at 08:59
-
1If using Xcode 8, I'd use signposts and the "Points of Interest" tool (http://stackoverflow.com/a/39416673/1271826) to narrow down the inspection range to the offending bit of code and highlight key events. So `kdebug_signpost_start` before performing the segue, and `kdebug_signpost_end` in the `viewDidAppear` of the destination and simple `kdebug_signpost` in a few of the routines in-between. – Rob Sep 22 '16 at 09:39