Forge
Forge

Reputation: 6834

Xcode constantly hangs on break points in a large project

In one of my projects, Xcode constantly hangs on every break point for at least a minute before responding. It only happens on that specific project which is fairly large, and has around 60 pods.

I tried restarting Xcode/my machine, deleting derivedData but no luck.

It's happening on Xcode 11.1, Xcode 11 and Xcode 10.

How would you suggest to debug this?

Upvotes: 3

Views: 868

Answers (1)

Smartcat
Smartcat

Reputation: 2882

I've seen breakpoints be slow (15 to 30 seconds, especially waiting for the variables view to stop spinning and appear). It seems especially bad in Xcode 11. I've also heard the same issues on some iOS podcasts in past few weeks (e.g. MTJC).

So here are some further ideas (beyond the ones you mentioned) that might just fix it for you:

  1. Remove all existing breakpoints before adding your new breakpoint.
  2. Avoid use of breakpoints that have "Automatically continue after evaluating actions".
  3. Avoid using other features of breakpoints... just use plain ole simple breakpoints.
  4. Avoid using breakpoints in tight loops of code.

Upvotes: 1

Related Questions