about summary refs log tree commit diff
path: root/compiler/rustc_data_structures
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-07-17 20:23:58 +0000
committerbors <bors@rust-lang.org>2021-07-17 20:23:58 +0000
commitc7331d65bdbab1187f5a9b8f5b918248678ebdb9 (patch)
tree0b2681f7ed2cd89df7cd8b8dfaf36c85dd6c7244 /compiler/rustc_data_structures
parent68511b574ffe019a5cb3e9fa92605f80d39167bc (diff)
parentfa839b1194a401c77a5fadba0a2b351870ea4683 (diff)
downloadrust-c7331d65bdbab1187f5a9b8f5b918248678ebdb9.tar.gz
rust-c7331d65bdbab1187f5a9b8f5b918248678ebdb9.zip
Auto merge of #87203 - jackh726:logging, r=nikomatsakis
Some perf optimizations and logging

Various bits of (potential) perf optimizations and some logging additions/changes pulled out from #85499

The only not extremely straightforward change is adding `needs_normalization` in `trait::project`. This is just a perf optimization to avoid fold through a type with *only* opaque types in `UserFacing` mode (as they aren't replaced).

This should be a simple PR for *anyone* to review, so I'm going to let highfive assign. But I'll go ahead and cc `@nikomatsakis` in case he has time today.
Diffstat (limited to 'compiler/rustc_data_structures')
-rw-r--r--compiler/rustc_data_structures/src/obligation_forest/mod.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/rustc_data_structures/src/obligation_forest/mod.rs b/compiler/rustc_data_structures/src/obligation_forest/mod.rs
index 05b1a85381f..25b7a84b3a0 100644
--- a/compiler/rustc_data_structures/src/obligation_forest/mod.rs
+++ b/compiler/rustc_data_structures/src/obligation_forest/mod.rs
@@ -418,6 +418,7 @@ impl<O: ForestObligation> ObligationForest<O> {
     /// be called in a loop until `outcome.stalled` is false.
     ///
     /// This _cannot_ be unrolled (presently, at least).
+    #[inline(never)]
     pub fn process_obligations<P, OUT>(&mut self, processor: &mut P) -> OUT
     where
         P: ObligationProcessor<Obligation = O>,
@@ -671,6 +672,7 @@ impl<O: ForestObligation> ObligationForest<O> {
         self.reused_node_vec = node_rewrites;
     }
 
+    #[inline(never)]
     fn apply_rewrites(&mut self, node_rewrites: &[usize]) {
         let orig_nodes_len = node_rewrites.len();