Function calculate_shift

Source
fn calculate_shift(a: u64, b: u64) -> u32
Expand description

Compute a ‘shift’ value such that (a * b) >> shift will be contained inside 64 bits.