Skip to content

Commit

Permalink
rustc_span: note the perf loss seen from IndexSet in symbol::Interner
Browse files Browse the repository at this point in the history
  • Loading branch information
cuviper committed Aug 9, 2020
1 parent 1d03ffe commit ca0b89a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/librustc_span/symbol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1481,6 +1481,10 @@ impl<CTX> ToStableHashKey<CTX> for Symbol {
}

// The `&'static str`s in this type actually point into the arena.
//
// The `FxHashMap`+`Vec` pair could be replaced by `FxIndexSet`, but #75278
// found that to regress performance up to 2% in some cases. This might be
// revisited after further improvements to `indexmap`.
#[derive(Default)]
pub struct Interner {
arena: DroplessArena,
Expand Down

0 comments on commit ca0b89a

Please sign in to comment.