diff options
| author | Eduard-Mihai Burtescu <edy.burt@gmail.com> | 2018-08-18 13:55:43 +0300 |
|---|---|---|
| committer | Eduard-Mihai Burtescu <edy.burt@gmail.com> | 2018-08-28 17:04:04 +0300 |
| commit | 93f3f5b1552489dbee03020505d896f01fd53852 (patch) | |
| tree | 19ccbcb3c491764f5ae6d3b65e1e0f76f450ce55 /src/librustc_codegen_llvm/back | |
| parent | 83ddc33347cade429fdb47509818e775a67c1af6 (diff) | |
| download | rust-93f3f5b1552489dbee03020505d896f01fd53852.tar.gz rust-93f3f5b1552489dbee03020505d896f01fd53852.zip | |
Use FxHash{Map,Set} instead of the default Hash{Map,Set} everywhere in rustc.
Diffstat (limited to 'src/librustc_codegen_llvm/back')
| -rw-r--r-- | src/librustc_codegen_llvm/back/linker.rs | 4 | ||||
| -rw-r--r-- | src/librustc_codegen_llvm/back/rpath.rs | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/librustc_codegen_llvm/back/linker.rs b/src/librustc_codegen_llvm/back/linker.rs index a429e8f2d81..24f6156bd76 100644 --- a/src/librustc_codegen_llvm/back/linker.rs +++ b/src/librustc_codegen_llvm/back/linker.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use std::collections::HashMap; +use rustc_data_structures::fx::FxHashMap; use std::ffi::{OsStr, OsString}; use std::fs::{self, File}; use std::io::prelude::*; @@ -30,7 +30,7 @@ use serialize::{json, Encoder}; /// For all the linkers we support, and information they might /// need out of the shared crate context before we get rid of it. pub struct LinkerInfo { - exports: HashMap<CrateType, Vec<String>>, + exports: FxHashMap<CrateType, Vec<String>>, } impl LinkerInfo { diff --git a/src/librustc_codegen_llvm/back/rpath.rs b/src/librustc_codegen_llvm/back/rpath.rs index 2c3a143646c..aa4f7688b0f 100644 --- a/src/librustc_codegen_llvm/back/rpath.rs +++ b/src/librustc_codegen_llvm/back/rpath.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use std::collections::HashSet; +use rustc_data_structures::fx::FxHashSet; use std::env; use std::path::{Path, PathBuf}; use std::fs; @@ -172,7 +172,7 @@ fn get_install_prefix_rpath(config: &mut RPathConfig) -> String { } fn minimize_rpaths(rpaths: &[String]) -> Vec<String> { - let mut set = HashSet::new(); + let mut set = FxHashSet::default(); let mut minimized = Vec::new(); for rpath in rpaths { if set.insert(rpath) { |
