Skip to content

Instantly share code, notes, and snippets.

@finestructure
Last active July 13, 2024 13:28
Show Gist options
  • Save finestructure/1a83888ff15d67b6d22515fd86328058 to your computer and use it in GitHub Desktop.
Save finestructure/1a83888ff15d67b6d22515fd86328058 to your computer and use it in GitHub Desktop.
Swift 6 preview test build
mkdir SwiftPackageIndex-Server && cd SwiftPackageIndex-Server
git init .
git remote add origin https://github.com/SwiftPackageIndex/SwiftPackageIndex-Server
git fetch origin --depth=1 89cbad3846eaef877ec33925eca5867922cf391a
git reset --hard FETCH_HEAD
mkdir .stats
time env DEVELOPER_DIR=/Applications/Xcode-16.0.0-Beta.3.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
@helje5
Copy link

helje5 commented Jul 13, 2024

2nd run after a swift package clean:

Build complete! (165.11s)
env DEVELOPER_DIR=/Applications/Xcode-16.0.0-Beta.3.app xcrun swift build      662.40s user 815.59s system 891% cpu 2:45.72 total

@finestructure
Copy link
Author

That's the complete build command including all the -Xswiftc flags and not just swift build, right?

@helje5
Copy link

helje5 commented Jul 13, 2024

helge@M2ni SwiftPackageIndex-Server % history
....
 1002  mkdir SwiftPackageIndex-Server && cd SwiftPackageIndex-Server\ngit init .\ngit remote add origin https://github.com/SwiftPackageIndex/SwiftPackageIndex-Server\ngit fetch origin --depth=1 89cbad3846eaef877ec33925eca5867922cf391a\ngit reset --hard FETCH_HEAD\nmkdir .stats\n
 1003  time env DEVELOPER_DIR=/Applications/Xcode-16.0.0-Beta.3.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
 1004  ls
 1005  swift package clean
 1006  time env DEVELOPER_DIR=/Applications/Xcode-16.0.0-Beta.3.app xcrun swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete

@cdf1982
Copy link

cdf1982 commented Jul 13, 2024

After swift package clean, my MBP16M3 16c (64GB/2TB) took 209.81s on battery; your times seems indeed long for a machine with many more cores.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment