Xcode Takes Long Time to Print Debug Results

Xcode 11 Debugger Extremely Slow

Yes, 11.2.1 was the fix provided by Apple

why is xcode console output sluggish after app launch in simulator?

So I ran a timer profile -- see this awesome article:

https://www.avanderlee.com/debugging/xcode-instruments-time-profiler/

I came up with this:

First snapshot

Which led to this:

Second Snapshot

And I understood where I introduced the problem:

var selectedNibIndex: Int = 0 {
didSet {
brush = WDBrush.from(index: selectedNibIndex)!
cameoImage = BrushStrokeImageView(paintBrush: brush)
dictionary = brush.wdPropertiesDictionary() as! [String: WDProperty]
}
}

this is new code, and it is placed inside a struct which is constantly being rebuilt.

I will move it out of there.

**

I guess the answer to my question is to run the app under the time
profiler and let it tell you where the problem is.

**

And marathon sessions aren't always a good idea. I would have caught the problem sooner if I hadn't bitten off such a big task. There was a two hour period where it wouldn't compile and I shouldn't have let that happen. By the time I got it to compile after some changes I had changed so many things I could no longer see the forest for the trees.

I hope this can help others, thanks for reading!

Xcode debugger doesn't print objects and shows nil, when they aren't

Are you sure you are not in "Release mode"?

If you want to see variable values you have to be in "Debug mode" (click on your project name on the top left corner near start/stop buttons, then "Edit scheme...", then "Run" settings, then "Info" tab, then "Build Configuration". Here set "Debug". If it was on "Release" that's the matter you saw all nils).

Xcode 4 - Debug Area no longer shows my console output (NSLog)

Not sure but may be you have clicked on one of the three buttons at the top right corner of the debug area that are used to either show only variables view, only the console or both.



Related Topics



Leave a reply



Submit