diff options
| author | bors <bors@rust-lang.org> | 2015-08-14 07:11:07 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2015-08-14 07:11:07 +0000 |
| commit | 0649b16ade40d1fb02ea5c390293278bd876854a (patch) | |
| tree | 3b6c52f5012c3dd32f2b6fc16d2ebdc10f5bfae0 /src/libstd | |
| parent | e907fab17812d1f6749a4a50ae248b205a7eca0f (diff) | |
| parent | 21eae93550216ca02c7fa949268d5d2907d36e26 (diff) | |
| download | rust-0649b16ade40d1fb02ea5c390293278bd876854a.tar.gz rust-0649b16ade40d1fb02ea5c390293278bd876854a.zip | |
Auto merge of #27822 - arielb1:inline-round-take-2, r=Gankro
This speeds up rustc on #25916 from 1.36±0.022s to 1.326±0.025s Tests pass locally (even on 32-bit :-) r? @Gankro
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/collections/hash/table.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libstd/collections/hash/table.rs b/src/libstd/collections/hash/table.rs index 8a822057bbf..e3601f1349c 100644 --- a/src/libstd/collections/hash/table.rs +++ b/src/libstd/collections/hash/table.rs @@ -511,6 +511,7 @@ impl<K, V, M: Deref<Target=RawTable<K, V>>> GapThenFull<K, V, M> { /// # Panics /// /// Panics if `target_alignment` is not a power of two. +#[inline] fn round_up_to_next(unrounded: usize, target_alignment: usize) -> usize { assert!(target_alignment.is_power_of_two()); (unrounded + target_alignment - 1) & !(target_alignment - 1) |
