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

Rework HIR API to make invocations of the hir_crate query harder. #88880

Merged
merged 5 commits into from
Oct 1, 2021

Conversation

cjgillot
Copy link
Contributor

hir_crate forces the recomputation of queries that depend on it.

This PR aims at avoiding useless invocations of hir_crate by making dependent code go through tcx.hir().

@rust-highfive
Copy link
Collaborator

Some changes occurred in src/tools/clippy.

cc @rust-lang/clippy

@rust-highfive
Copy link
Collaborator

r? @wesleywiser

(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 Sep 12, 2021
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@cjgillot
Copy link
Contributor Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

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

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Sep 12, 2021
@bors
Copy link
Contributor

bors commented Sep 12, 2021

⌛ Trying commit 2067357c615db4c3df72eca28d54b3e8572255d2 with merge 61a27a20fa9db4b749e8bf81b59fc0bcb5d60587...

@bors
Copy link
Contributor

bors commented Sep 12, 2021

☀️ Try build successful - checks-actions
Build commit: 61a27a20fa9db4b749e8bf81b59fc0bcb5d60587 (61a27a20fa9db4b749e8bf81b59fc0bcb5d60587)

@rust-timer
Copy link
Collaborator

Queued 61a27a20fa9db4b749e8bf81b59fc0bcb5d60587 with parent 0212c70, future comparison URL.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (61a27a20fa9db4b749e8bf81b59fc0bcb5d60587): comparison url.

Summary: This benchmark run did not return any relevant changes.

If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf.

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR led to changes in compiler perf.

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

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Sep 12, 2021
Copy link
Contributor

@oli-obk oli-obk left a comment

Choose a reason for hiding this comment

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

The title of the PR says that hir_crate query calls are avoided, but the PR code looks to me like it's "just" (in quotes, because it is a good) clean up and API simplification. Am I missing something or should the title get updated?

compiler/rustc_middle/src/hir/map/mod.rs Outdated Show resolved Hide resolved
@@ -23,7 +23,13 @@ LL | pub fn foo() {}

error: requires `sized` lang_item

error: aborting due to 3 previous errors
error: requires `sized` lang_item
Copy link
Contributor

Choose a reason for hiding this comment

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

Not very important (deduplicated for users anyway), but any idea why these are tripled?

Copy link
Member

Choose a reason for hiding this comment

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

I'm also curious about this.

compiler/rustc_hir/src/hir.rs Outdated Show resolved Hide resolved
@cjgillot
Copy link
Contributor Author

My first aim was to remove calls to tcx.hir().krate() which are exactly calls to tcx.hir_crate(()). Hence the PR title. Cleaning-up the API to make this function harder to use is only a second-order goal.

@oli-obk
Copy link
Contributor

oli-obk commented Sep 13, 2021

Right, I got that, but it looks to me like the same amount of calls are still happening, but they are now hidden behind new functions.

@cjgillot cjgillot changed the title Avoid more invocations of hir_crate query. Rework HIR API to make invocations of the hir_crate query harder. Sep 13, 2021
@bors
Copy link
Contributor

bors commented Sep 29, 2021

☔ The latest upstream changes (presumably #89328) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Oct 1, 2021
@bors
Copy link
Contributor

bors commented Oct 1, 2021

⌛ Testing commit 77c3002 with merge cca895bdbd29df606af923faf3967edda3ee16ba...

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-aux failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)

failures:

---- test_sort::prop_sort_no_headers stdout ----
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-546]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-560]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
error: test failed, to rerun pass '--test tests'
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-577]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-591]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-606]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-619]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-633]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-646]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-662]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-674]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-690]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-702]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-717]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-728]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-740]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-753]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-767]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-782]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-796]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-811]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-825]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-839]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-852]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-867]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-880]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-894]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-908]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-923]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-936]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-952]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-966]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-979]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-989]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1004]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1017]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1032]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1044]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1059]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1071]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1085]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1101]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1116]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1129]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1143]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1156]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1171]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1183]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1196]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1210]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1222]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1237]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1250]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1264]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1277]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1290]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1304]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1317]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", ""], ["", ""], ["", "\u{15}"], ["", "%\""], ["", "V:%~"], ["", "⽊\u{19f90}:⻕"], ["", "㨶Yࡧ}"], ["", "\u{6fc2f}"], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["\u{14}#w\u{f0000}", "\u{98}"], ["\u{19}\u{6dd}", ""], ["\u{1f}.\u{84}\u{8b}", "\"⁜"], [" ^", " \u{2}\u{8a}\u{f}"], ["!⁗\u{1d173}}", "6\u{11}"], ["!䫅", "£\u{c}?"], ["#^9\"", "\u{e3cc0}"], ["$\n.", "⁍R"], ["%", ""], ["%;", "$"], ["./f\u{8b51a}", "."], ["/", "\u{1c}"], ["2", " "], ["2(\u{1}", ""], ["4%", "2h"], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["8lN", "®"], ["=⫰\u{17}>", "녫|J"], ["A\u{1}", "-"], ["J{a—", ""], ["L\u{61c} ", "\u{85}9弊"], ["`", ""], ["a%}", "0\u{202a}\u{92}"], ["av\u{1d}", "O"], ["e~", ""], ["e\u{fffb}", "흣\u{91}\u{9c2bd}"], ["n\\ ", "=\u{8d}"], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{8c}", "@{%"], ["\u{8f}/", "b ^L"], ["\u{95}", "\u{16}"], ["\u{a0}]⁜\u{6776a}", "\u{80}\u{8e}"], ["¯뒯}ጦ", "Xª"], ["\u{33b}/", "\u{96}"], ["\u{603}", "垼\u{fffa}"], ["″⁊", "\u{8c}"], ["㏥~\u{84}", "‴挑\u{fff3}t"], ["冎⪿7", "⬓藦\u{16}"], ["砛:", "ጞ"], ["筃)k#", "o¯\u{10fffe}\u{1e}"], ["顦ZbG", "\u{6}"], ["\u{fffb}l}", "‟`P"], ["\u{16a8d}{0", "C\u{b}"], ["\u{4fdda}=", "/!}"]]`,
 right: `[["", ""], ["", ""], ["", ""], ["", "%\""], ["", "V:%~"], ["", "⽊\u{19f90}:⻕"], ["", "㨶Yࡧ}"], ["", "\u{6fc2f}"], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["\u{14}#w\u{f0000}", "\u{98}"], ["\u{19}\u{6dd}", ""], ["\u{1f}.\u{84}\u{8b}", "\"⁜"], [" ^", " \u{2}\u{8a}\u{f}"], ["!⁗\u{1d173}}", "6\u{11}"], ["!䫅", "£\u{c}?"], ["#^9\"", "\u{e3cc0}"], ["$\n.", "⁍R"], ["%", ""], ["%;", "$"], ["./f\u{8b51a}", "."], ["/", "\u{1c}"], ["2", " "], ["2(\u{1}", ""], ["4%", "2h"], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["8lN", "®"], ["=⫰\u{17}>", "녫|J"], ["A\u{1}", "-"], ["J{a—", ""], ["L\u{61c} ", "\u{85}9弊"], ["`", ""], ["a%}", "0\u{202a}\u{92}"], ["av\u{1d}", "O"], ["e~", ""], ["e\u{fffb}", "흣\u{91}\u{9c2bd}"], ["n\\ ", "=\u{8d}"], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{8c}", "@{%"], ["\u{8f}/", "b ^L"], ["\u{95}", "\u{16}"], ["\u{a0}]⁜\u{6776a}", "\u{80}\u{8e}"], ["¯뒯}ጦ", "Xª"], ["\u{33b}/", "\u{96}"], ["\u{603}", "垼\u{fffa}"], ["″⁊", "\u{8c}"], ["㏥~\u{84}", "‴挑\u{fff3}t"], ["冎⪿7", "⬓藦\u{16}"], ["砛:", "ጞ"], ["筃)k#", "o¯\u{10fffe}\u{1e}"], ["顦ZbG", "\u{6}"], ["\u{feff}", "\u{15}"], ["\u{fffb}l}", "‟`P"], ["\u{16a8d}{0", "C\u{b}"], ["\u{4fdda}=", "/!}"]]`', tests/test_sort.rs:24:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1345]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1358]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1369]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", ""], ["", "\u{15}"], ["", "⽊\u{19f90}:⻕"], ["", "㨶Yࡧ}"], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["\u{1f}.\u{84}\u{8b}", "\"⁜"], ["$\n.", "⁍R"], ["%;", "$"], ["2", " "], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["=⫰\u{17}>", "녫|J"], ["A\u{1}", "-"], ["J{a—", ""], ["`", ""], ["a%}", "0\u{202a}\u{92}"], ["av\u{1d}", "O"], ["e~", ""], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{8f}/", "b ^L"], ["¯뒯}ጦ", "Xª"], ["\u{33b}/", "\u{96}"], ["\u{603}", "垼\u{fffa}"], ["㏥~\u{84}", "‴挑\u{fff3}t"], ["砛:", "ጞ"], ["顦ZbG", "\u{6}"]]`,
 right: `[["", ""], ["", ""], ["", "⽊\u{19f90}:⻕"], ["", "㨶Yࡧ}"], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["\u{1f}.\u{84}\u{8b}", "\"⁜"], ["$\n.", "⁍R"], ["%;", "$"], ["2", " "], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["=⫰\u{17}>", "녫|J"], ["A\u{1}", "-"], ["J{a—", ""], ["`", ""], ["a%}", "0\u{202a}\u{92}"], ["av\u{1d}", "O"], ["e~", ""], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{8f}/", "b ^L"], ["¯뒯}ጦ", "Xª"], ["\u{33b}/", "\u{96}"], ["\u{603}", "垼\u{fffa}"], ["㏥~\u{84}", "‴挑\u{fff3}t"], ["砛:", "ጞ"], ["顦ZbG", "\u{6}"], ["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1386]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1398]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1411]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", "\u{15}"], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["$\n.", "⁍R"], ["2", " "], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["=⫰\u{17}>", "녫|J"], ["e~", ""], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{603}", "垼\u{fffa}"], ["砛:", "ጞ"], ["顦ZbG", "\u{6}"]]`,
 right: `[["", ""], ["\u{4}\u{f73cf}恵\u{fff4}", ";+"], ["\r-`", "\u{95}\"("], ["$\n.", "⁍R"], ["2", " "], ["4蝠\"", " "], ["5쁑", "[*\u{8f}"], ["=⫰\u{17}>", "녫|J"], ["e~", ""], ["r", "\t\u{10eb25}\u{f28a}"], ["\u{603}", "垼\u{fffa}"], ["砛:", "ጞ"], ["顦ZbG", "\u{6}"], ["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1423]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1436]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1447]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", "\u{15}"], ["\r-`", "\u{95}\"("], ["2", " "], ["4蝠\"", " "], ["e~", ""], ["\u{603}", "垼\u{fffa}"]]`,
 right: `[["", ""], ["\r-`", "\u{95}\"("], ["2", " "], ["4蝠\"", " "], ["e~", ""], ["\u{603}", "垼\u{fffa}"], ["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1458]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1467]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1477]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", "\u{15}"], ["2", " "], ["4蝠\"", " "]]`,
 right: `[["", ""], ["2", " "], ["4蝠\"", " "], ["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1486]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1498]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1507]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""], ["", "\u{15}"]]`,
 right: `[["", ""], ["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1516]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1528]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1538]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", "\u{15}"]]`,
 right: `[["\u{feff}", "\u{15}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1548]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1558]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1568]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1578]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1590]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1598]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1610]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1619]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1628]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1638]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1650]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1659]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1671]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1680]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1687]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1689]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1694]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1696]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[["", ""]]`,
 right: `[["\u{feff}", ""]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1701]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1703]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1708]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1709]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1713]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1714]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1718]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1719]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1723]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1724]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1728]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1729]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1732]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1734]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1737]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1739]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1742]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1744]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1747]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1749]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at 'assertion failed: `(left == right)`
  left: `[]`,
 right: `[["\u{feff}"]]`', tests/test_sort.rs:24:5
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1752]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1754]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1757]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1758]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1762]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1763]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1767]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1768]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1772]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1773]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1777]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1778]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1782]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1783]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1787]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1788]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
[/checkout/obj/build/ct/xsv/target/debug/xit/prop_sort_no_headers/test-1792]: "/checkout/obj/build/ct/xsv/target/debug/xsv" "sort" "in.csv" "--no-headers"
thread 'test_sort::prop_sort_no_headers' panicked at '[quickcheck] TEST FAILED (runtime error). Arguments: (CsvData { data: [[[239, 187, 191]]] })
Error: "assertion failed: `(left == right)`\n  left: `[]`,\n right: `[[\"\\u{feff}\"]]`"', /cargo/registry/src/github.com-1ecc6299db9ec823/quickcheck-0.7.1/src/tester.rs:176:28

failures:
    test_sort::prop_sort_no_headers


test result: FAILED. 425 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 13.71s

thread 'main' panicked at 'tests failed for https://github.com/BurntSushi/xsv', src/tools/cargotest/main.rs:101:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
make: *** [check-aux] Error 1

command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/cargotest" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools-bin/cargo" "/checkout/obj/build/ct"
expected success, got: exit status: 101



Build completed unsuccessfully in 0:28:11
Makefile:44: recipe for target 'check-aux' failed

@bors
Copy link
Contributor

bors commented Oct 1, 2021

💔 Test failed - checks-actions

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

oli-obk commented Oct 1, 2021

@bors retry

@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 Oct 1, 2021
@bors
Copy link
Contributor

bors commented Oct 1, 2021

⌛ Testing commit 77c3002 with merge c02371c...

@bors
Copy link
Contributor

bors commented Oct 1, 2021

☀️ Test successful - checks-actions
Approved by: oli-obk
Pushing c02371c to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Oct 1, 2021
@bors bors merged commit c02371c into rust-lang:master Oct 1, 2021
@rustbot rustbot added this to the 1.57.0 milestone Oct 1, 2021
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (c02371c): comparison url.

Summary: This benchmark run did not return any relevant changes.

If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf.

@rustbot label: -perf-regression

@cjgillot cjgillot deleted the no-krate branch October 3, 2021 10:40
@Mark-Simulacrum Mark-Simulacrum added the perf-regression Performance regression. label Oct 5, 2021
@Mark-Simulacrum
Copy link
Member

Tagging as a perf regression. Our heuristics currently didn't flag this earlier, but it seems like many-assoc-items is indeed regressed by this PR.

flip1995 pushed a commit to flip1995/rust that referenced this pull request Oct 7, 2021
Rework HIR API to make invocations of the hir_crate query harder.

`hir_crate` forces the recomputation of queries that depend on it.

This PR aims at avoiding useless invocations of `hir_crate` by making dependent code go through `tcx.hir()`.
bors added a commit to rust-lang-ci/rust that referenced this pull request Oct 18, 2021
Index and hash HIR as part of lowering

Part of rust-lang#88186
~Based on rust-lang#88880 (see merge commit).~

Once HIR is lowered, it is later indexed by the `index_hir` query and hashed for `crate_hash`. This PR moves those post-processing steps to lowering itself. As a side objective, the HIR crate data structure is refactored as an `IndexVec<LocalDefId, Option<OwnerInfo<'hir>>>` where `OwnerInfo` stores all the relevant information for an HIR owner.

r? `@michaelwoerister`
cc `@petrochenkov`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants