Skip to content

[Tests] Do not share underlying Oracle for caching tests #1954

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
Jul 9, 2025

Conversation

cachemeifyoucan
Copy link
Contributor

After rewriting the scanning service, oracle can get a race condition when CAS configuration is changed in between builds. It causes clang dependency scanning using a wrong CAS when scanning after some other thread updated the CAS location.

Fix the occasional race condition by not sharing the orcale between all the tests sicne this is not a valid real world configuration. In the future, we should teach clang scanner not to hold a global CAS instance so service can be shared when switching CAS locations in a racy way.

rdar://154592458

@cachemeifyoucan cachemeifyoucan requested a review from artemcm July 7, 2025 21:37
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test

After rewriting the scanning service, oracle can get a race condition
when CAS configuration is changed in between builds. It causes clang
dependency scanning using a wrong CAS when scanning after some other
thread updated the CAS location.

Fix the occasional race condition by not sharing the orcale between all
the tests sicne this is not a valid real world configuration. In the
future, we should teach clang scanner not to hold a global CAS instance
so service can be shared when switching CAS locations in a racy way.

rdar://154592458
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test

@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test windows platform

2 similar comments
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test windows platform

@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test windows platform

@cachemeifyoucan cachemeifyoucan enabled auto-merge July 8, 2025 20:38
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please test windows platform

@cachemeifyoucan cachemeifyoucan merged commit 446fc58 into swiftlang:main Jul 9, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants