Skip to content

[Caching] Downgrade output loading error to a warning #77934

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
merged 1 commit into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions include/swift/AST/DiagnosticsFrontend.def
Original file line number Diff line number Diff line change
Expand Up @@ -511,6 +511,7 @@ REMARK(output_cache_miss, none, "cache miss for input file '%0': key '%1'", (Str

// CAS related diagnostics
ERROR(error_cas, none, "CAS error encountered: %0", (StringRef))
WARNING(cache_replay_failed, none, "cache replay failed: %0", (StringRef))

ERROR(error_failed_cached_diag, none, "failed to serialize cached diagnostics: %0", (StringRef))
ERROR(error_replay_cached_diag, none, "failed to replay cached diagnostics: %0", (StringRef))
Expand Down
3 changes: 2 additions & 1 deletion lib/Frontend/CachingUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,8 @@ bool replayCachedCompilerOutputs(
OutputEntry{OutputPath->second, OutID, Kind, Input, *Proxy});
return Error::success();
})) {
Diag.diagnose(SourceLoc(), diag::error_cas, toString(std::move(Err)));
Diag.diagnose(SourceLoc(), diag::cache_replay_failed,
toString(std::move(Err)));
return lookupFailed();
}
};
Expand Down