canary: profile the cmuxTests emit-module job (do not merge)

Draft
TE
2mo ago
+266-2

Canary, do not merge. Profiles the cmuxTests SwiftEmitModule job, which is 26 s of the 31 s a one-test-file rebuild costs once #14349 lands (canary #14249, run 36081880621).

After the admission compile, scripts/ci/canary-cmuxtests-emit-module.sh rebuilds cmux-unit in six series. Each series rebuilds cmuxTests with its own arguments, then makes two one-test-file body edits. Only cmuxTests' arguments change ($(X_$(TARGET_NAME))); every series records -stats-output-dir + -fine-grained-timers and long type-check warnings.

  • control: stats only, plus -debug-time-function-bodies
  • noobjc: SWIFT_OBJC_INTERFACE_HEADER_NAME = "" on cmuxTests (nothing imports cmuxTests-Swift.h)
  • noabi: -Xfrontend -empty-abi-descriptor
  • lean: both, plus -avoid-emit-module-source-info
  • lazy: lean plus -experimental-lazy-typecheck
  • legacy-merge: SWIFT_USE_INTEGRATED_DRIVER=NO + -no-emit-module-separately for cmuxTests

๐Ÿค– Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Summary by cubic

Canary, do not merge: profiles cmuxTests' SwiftEmitModule job, which is 26 s of the ~31 s a one-test-file rebuild costs once #14349 lands.

Probe

  • canary-cmuxtests-emit-module.sh rebuilds cmuxTests in five series that each vary only its build flags, edits one test body, and rebuilds; every build appends per-task wall times and long type-check warnings to the job summary.
  • nomodule and nomodule-explicit drop the separate emit-module job via -no-emit-module-separately with the integrated driver off; legacy additionally drops the ObjC interface header; base and lazy keep it.
  • The probe measures without -stats-output-dir since fine-grained timers double emit-module time, and verifies a no-module build cannot drop tests by enumerating the built bundle.

CI

  • Pins the admission build job to a canary runner with a 240-minute timeout and uploads probe logs โ€” both must be reverted before merging.