swift run on Xcode 16 beta 2 for Swift Package crashes with SIGKILL Guard

With connection of SSH via Jenkins 2.332.1 to the remote Macs, swift-package module crashes and leaves crash report on Console. Absolutely swift command itself fails.

Filed https://feedbackassistant.apple.com/feedback/14285692 with the crash report created.

Really hard to explain what happens exactly but seems like it is related to Xcode 16 beta (xcrun version 70) because the same problem never occurs on Xcode 15.4 (xcrun version 68).

Finally got how this crash can be reproduced.

This is very specific with Xcode 16 betas, recurring on Apple Silicon mac mini/macbook pro 14'' Sonoma 14.5, with CrowdStrike Falcon Sensor 7.14.18305.0 running.

If you run swift run -c release swiftformat ./ with all caches and build artifacts of Swift Package, the shell will crash with SIGKILL and send crash report to you local Console.app.

So the solution will be: separating swift build and swift run. After that we never complain of swift run crashes.

swift run on Xcode 16 beta 2 for Swift Package crashes with SIGKILL Guard
 
 
Q