diff options
| author | bors <bors@rust-lang.org> | 2021-09-05 21:40:34 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-09-05 21:40:34 +0000 |
| commit | 7849e3e9dda60e8ec826ee245c6b180e73911b37 (patch) | |
| tree | d10bb20b5a49755a917bc020cc1a55ccc6203ff7 /compiler/rustc_interface/src | |
| parent | e30b68353fe22b00f40d021e7914eeb78473b3c1 (diff) | |
| parent | d119a131374b973f0a1ae9d723c3a9ad518b8049 (diff) | |
| download | rust-7849e3e9dda60e8ec826ee245c6b180e73911b37.tar.gz rust-7849e3e9dda60e8ec826ee245c6b180e73911b37.zip | |
Auto merge of #88435 - cjgillot:no-walk-crate, r=Aaron1011
Avoid invoking the hir_crate query to traverse the HIR Walking the HIR tree is done using the `hir_crate` query. However, this is unnecessary, since `hir_owner(CRATE_DEF_ID)` provides the same information. Since depending on `hir_crate` forces dependents to always be executed, this leads to unnecessary work. By splitting HIR and attributes visits, we can avoid an edge to `hir_crate` when trying to visit the HIR tree.
Diffstat (limited to 'compiler/rustc_interface/src')
| -rw-r--r-- | compiler/rustc_interface/src/passes.rs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/compiler/rustc_interface/src/passes.rs b/compiler/rustc_interface/src/passes.rs index 7127ec57c08..1d542db9b69 100644 --- a/compiler/rustc_interface/src/passes.rs +++ b/compiler/rustc_interface/src/passes.rs @@ -464,10 +464,6 @@ pub fn lower_to_hir<'res, 'tcx>( arena, ); - if sess.opts.debugging_opts.hir_stats { - hir_stats::print_hir_stats(&hir_crate); - } - sess.time("early_lint_checks", || { rustc_lint::check_ast_crate( sess, |
