Xcode 14.2 incredible slow incremental build time

Since Xcode 14.0.1 I have the problem that subsequent builds takes longer and longer to be finished. The problem occurs only if the program is started once a time and then rebuild. From this point subsequent builds via ⌘B increase the total time to build with every additional run. Interestingly the total build time of a C++ project increases exponentially whereas a pure Storyboard Swift-based project seems to be increase linear in time.

In my case after 10 recompilations you have to wait more than 1 minute to complete even for small projects with just a dozen files to compile. The only workaround is to close/reopen the project. But it's not a solution.

It doesn't matter whether the code base is changing or not, the build time increases in any case. Because this phenomenon is a real showstopper when developing software, I downgrade Xcode to version 13.4.1 (13F100). And all problems gone.

The problem I describe above is documented at least on two places, here Stackoverflow and here SWIFT Forum

There are one suggestions to circumvent the problem but in my case this seems not to work:

  1. Setting SWIFT_USE_INTEGRATED_DRIVER=NO in the target

Downgrading to Xcode 13.4.1 seems the best workaround. The IMac M1 operates with the latest Monterey version 12.6.2.

Xcode 14.2 incredible slow incremental build time
 
 
Q