Skip to content

Commit

Permalink
Add inline flag on folded_multiply
Browse files Browse the repository at this point in the history
Signed-off-by: Tom Kaitchuck <Tom.Kaitchuck@gmail.com>
  • Loading branch information
tkaitchuck committed May 25, 2021
1 parent 6249bbd commit 2af569a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/operations.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const SHUFFLE_MASK: u128 = 0x020a0700_0c01030e_050f0d08_06090b04_u128;
//const SHUFFLE_MASK: u128 = 0x000d0702_0a040301_05080f0c_0e0b0609_u128;
//const SHUFFLE_MASK: u128 = 0x040A0700_030E0106_0D050F08_020B0C09_u128;

#[inline(always)]
pub(crate) const fn folded_multiply(s: u64, by: u64) -> u64 {
let result = (s as u128).wrapping_mul(by as u128);
((result & 0xffff_ffff_ffff_ffff) as u64) ^ ((result >> 64) as u64)
Expand Down

0 comments on commit 2af569a

Please sign in to comment.