Skip to content
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

Make weak item traversal deterministic #81393

Conversation

pnkfelix
Copy link
Member

@pnkfelix pnkfelix commented Jan 25, 2021

Fix #81296.

(No test added. The relevant test is ui/panic-handler/weak-lang-item.rs, and this change should make it less flaky.)

(No test added. The relevant test *is* ui/panic-handler/weak-lang-item.rs, and this change should make it less flaky.)
@rust-highfive
Copy link
Collaborator

r? @estebank

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 25, 2021
@pnkfelix
Copy link
Member Author

I do want a perf run on this b/c is adding a clone

@Aaron1011
Copy link
Member

@pnkfelix Did you mean issue #81296?

@@ -59,7 +59,7 @@ fn verify<'tcx>(tcx: TyCtxt<'tcx>, items: &lang_items::LanguageItems) {
}
}

for (name, &item) in WEAK_ITEMS_REFS.iter() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WEAK_ITEMS_REFS is already a StableMap now, do you need to sort it? The only reason I am commenting on it is that I am slightly saddened by the new .clone() (but I'll get over it).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is the one turning it into a StableMap, and the sort is necessary to normalize the order, right?

(That is: If we don't normalize the order, then we don't get the benefit of this change, right?)

To be clear: I too am saddened by the .clone(), and you might talk me into just using a different structure entirely. This seemed like the simplest fix, and if we're going to balk at doing it in this scenario, then maybe we should remove StableMap entirely and figure out a different way to discourage people from using FxHashMap?

@estebank
Copy link
Contributor

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@bors
Copy link
Contributor

bors commented Jan 26, 2021

⌛ Trying commit 4c5ede7 with merge 74e3708d92e199707b5b924507f40e55ca493b8f...

@bors
Copy link
Contributor

bors commented Jan 26, 2021

☀️ Try build successful - checks-actions
Build commit: 74e3708d92e199707b5b924507f40e55ca493b8f (74e3708d92e199707b5b924507f40e55ca493b8f)

@rust-timer
Copy link
Collaborator

Queued 74e3708d92e199707b5b924507f40e55ca493b8f with parent f4eb5d9, future comparison URL.

@rustbot label: +S-waiting-on-perf

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 26, 2021
@rust-timer
Copy link
Collaborator

Finished benchmarking try commit (74e3708d92e199707b5b924507f40e55ca493b8f): comparison url.

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. Please note that if the perf results are neutral, you should likely undo the rollup=never given below by specifying rollup- to bors.

Importantly, though, if the results of this run are non-neutral do not roll this PR up -- it will mask other regressions or improvements in the roll up.

@bors rollup=never
@rustbot label: +S-waiting-on-review -S-waiting-on-perf

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 26, 2021
@camelid
Copy link
Member

camelid commented Jan 26, 2021

Perf looks fairly neutral to me.

@estebank
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Jan 26, 2021

📌 Commit 4c5ede7 has been approved by estebank

@bors
Copy link
Contributor

bors commented Jan 26, 2021

🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 26, 2021
@bors
Copy link
Contributor

bors commented Jan 27, 2021

⌛ Testing commit 4c5ede7 with merge 78e2206...

@bors
Copy link
Contributor

bors commented Jan 27, 2021

☀️ Test successful - checks-actions
Approved by: estebank
Pushing 78e2206 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jan 27, 2021
@bors bors merged commit 78e2206 into rust-lang:master Jan 27, 2021
@rustbot rustbot added this to the 1.51.0 milestone Jan 27, 2021
@jieyouxu jieyouxu added A-testsuite Area: The testsuite used to check the correctness of rustc T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Aug 14, 2024
@jieyouxu jieyouxu added the A-reproducibility Area: Reproducible / deterministic builds label Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-reproducibility Area: Reproducible / deterministic builds A-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Semi-spurious ui test fluctuation
9 participants