Skip to content

[SourceKit] Don’t set DisableModulesValidateSystemDependencies to true #74213

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Jun 7, 2024

  • Explanation: It appears that swiftlang/llvm-project@a6ebd30 changed the behavior of -fno-modules-validate-system-headers (aka. DisableModulesValidateSystemDependencies) in conjunction with -fmodules-validate-once-per-build-session: Before that change, -fno-modules-validate-system-headers needed to be passed for -fmodules-validate-once-per-build-session to have any effect (we were always validating system dependencies if -fno-modules-validate-once-per-build-session was not set). After the change, -fno-modules-validate-once-per-build-session causes system dependencies to never be validated, independent of the build session timestamp.
    This change should have no effect on Xcode because it adds -fmodules-validate-system-headers to the compiler arguments for Swift files, which overrides SearchPathOpts.DisableModulesValidateSystemDependencies = true;
  • Scope: SourceKit for system modules that are modified
  • Risk: Low
  • Testing: Added test case
  • Issue: rdar://129046909
  • Reviewer: @bnbarham on [SourceKit] Don’t set DisableModulesValidateSystemDependencies to true #74063

…true`

It appears that swiftlang/llvm-project@a6ebd30 changed the behavior of `-fno-modules-validate-system-headers` (aka. `DisableModulesValidateSystemDependencies`) in conjunction with `-fmodules-validate-once-per-build-session`: Before that change, `-fno-modules-validate-system-headers` needed to be passed for `-fmodules-validate-once-per-build-session` to have any effect (we were always validating system dependencies if `-fno-modules-validate-once-per-build-session` was not set). After the change, `-fno-modules-validate-once-per-build-session` causes system dependencies to never be validated, independent of the build session timestamp.

This change should have no effect on Xcode because it adds `-fmodules-validate-system-headers` to the compiler arguments for Swift files, which overrides `SearchPathOpts.DisableModulesValidateSystemDependencies = true;`
@ahoppen ahoppen requested a review from bnbarham June 7, 2024 17:24
@ahoppen ahoppen requested a review from a team as a code owner June 7, 2024 17:24
@ahoppen
Copy link
Member Author

ahoppen commented Jun 7, 2024

@swift-ci Please test

@ahoppen ahoppen merged commit a0bb875 into swiftlang:release/6.0 Jun 7, 2024
5 checks passed
@ahoppen ahoppen deleted the 6.0/validate-system-dependencies branch June 7, 2024 23:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants