Skip to content

Commit b806efc

Browse files
committed
Move incremental compilation section to the top
1 parent bf823e1 commit b806efc

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ Swift is constantly improving ❤️. For the time being, though, long compile t
88

99
# Table of contents
1010

11+
- [Incremental Compilation Mode with No Optimization](#incremental-compilation-mode-with-no-optimization)
1112
- [Type checking of functions and expressions](#type-checking-of-functions-and-expressions)
1213
- [Slowly compiling files](#slowly-compiling-files)
1314
- [Build active architecture only](#build-active-architecture-only)
1415
- [dSYM generation](#dsym-generation)
15-
- [Incremental Compilation Mode with No Optimization](#incremental-compilation-mode-with-no-optimization)
1616
- [Third-party dependencies](#third-party-dependencies)
1717
- [Modularization](#modularization)
1818
- [XIBs](#xibs)
@@ -21,6 +21,18 @@ Swift is constantly improving ❤️. For the time being, though, long compile t
2121
- [Enable concurrent Swift build tasks](#enable-concurrent-swift-build-tasks)
2222
- [Showing build times in Xcode](#showing-build-times-in-xcode)
2323

24+
# Incremental Compilation Mode with No Optimization
25+
26+
Until Xcode 10, it was common to enable [Whole Module Optimization](https://github.com/fastred/Optimizing-Swift-Build-Times/blob/ce6da1f3a47220259c3924df62f44f06bc45e222/README.md#whole-module-optimization) to speed up Debug builds. It was a workaround that's no longer needed in Xcode 10!
27+
28+
Currently, the recommended setup is to have `Incremental` `Compilation Mode` set for Debug builds and `Whole Module` for Release builds. Also, `No Optimization` should be chosen for `Optimization Level` of Debug builds.
29+
30+
<img src="assets/compilation-and-optimization@2x.png" width="551">
31+
32+
📖 Sources:
33+
34+
- [What's New in Swift – WWDC 2018](https://developer.apple.com/videos/play/wwdc2018/401/?time=657)
35+
2436
# Type checking of functions and expressions
2537

2638
Swift build times are slow mostly because of expensive type checking. By default Xcode doesn't show code that's slow to compile. You can instruct it to show slowly compiling functions and expressions, though by adding:
@@ -110,18 +122,6 @@ Recommended setup:
110122

111123
- [Speeding up Development Build Times With Conditional dSYM Generation](http://holko.pl/2016/10/18/dsym-debug/)
112124

113-
# Incremental Compilation Mode with No Optimization
114-
115-
Until Xcode 10, it was common to enable [Whole Module Optimization](https://github.com/fastred/Optimizing-Swift-Build-Times/blob/ce6da1f3a47220259c3924df62f44f06bc45e222/README.md#whole-module-optimization) to speed up Debug builds. It was a workaround that's no longer needed in Xcode 10!
116-
117-
Currently, the recommended setup is to have `Incremental` `Compilation Mode` set for Debug builds and `Whole Module` for Release builds. Also, `No Optimization` should be chosen for `Optimization Level` of Debug builds.
118-
119-
<img src="assets/compilation-and-optimization@2x.png" width="551">
120-
121-
📖 Sources:
122-
123-
- [What's New in Swift – WWDC 2018](https://developer.apple.com/videos/play/wwdc2018/401/?time=657)
124-
125125
# Third-party dependencies
126126

127127
There are two ways you can embed third-party dependencies in your projects:

0 commit comments

Comments
 (0)