Skip to content

Commit 94f2c0d

Browse files
author
Dave Abrahams
authored
Further clarification
1 parent 1ca367d commit 94f2c0d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/DevelopmentTips.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@ Compilation times for the compiler and the standard library can be agonizing, es
3232

3333
```
3434
$ brew install sccache
35-
$ sccache --start-server
3635
$ ./swift/utils/build-script MY_ARGS --sccache
3736
```
3837

3938
If you want to always use sccache, you can `export SWIFT_USE_SCCACHE=1` and omit the `--sccache` flag from the `build-script` invocation.
4039

41-
Given the size of artifacts generated, you might also want to bump the cache size from the default 10GB to something larger, say by putting `export SCCACHE_CACHE_SIZE="50G"` in your dotfile(s).
40+
Given the size of artifacts generated, you might also want to bump the cache size from the default 10GB to something larger, say by putting `export SCCACHE_CACHE_SIZE="50G"` in your dotfile(s). You'll need to restart the `sccache` server after changing that environment variable
41+
(`sccache --stop-server && sccache --start-server`).
4242

4343
You can run some compiles to see if it is actually doing something by running `sccache --show-stats`. Depending on the exact compilation task you're running, you might see very different cache hit rates. For example, `sccache` is particularly effective if you're rebuilding LLVM, which doesn't change so frequently from the Swift compiler's perspective. On the other hand, if you're changing the compiler's AST, the cache hit rate is likely to be much lower.
4444

0 commit comments

Comments
 (0)