mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[SourceKit] Disable module system headers validation
in all SourceKit requests. This validation may call many stat(2). Since we don't expect system files are edited. Disable it for SourceKit requests. Even if they are edited, manual builds can validates and updates them. rdar://problem/58550697
This commit is contained in:
@@ -539,6 +539,11 @@ bool SwiftASTManager::initCompilerInvocation(
|
||||
// We don't care about LLVMArgs
|
||||
FrontendOpts.LLVMArgs.clear();
|
||||
|
||||
// This validation may call stat(2) many times. Disable it to prevent
|
||||
// performance issues.
|
||||
Invocation.getSearchPathOptions().DisableModulesValidateSystemDependencies =
|
||||
true;
|
||||
|
||||
// SwiftSourceInfo files provide source location information for decls coming
|
||||
// from loaded modules. For most IDE use cases it either has an undesirable
|
||||
// impact on performance with no benefit (code completion), results in stale
|
||||
|
||||
Reference in New Issue
Block a user