Coerce an object to a 60-bit natural.
(60-bit-fix x) → *
A previous definition for this function was:
(the (signed-byte 61) (if (integerp x) (logand x (the (signed-byte 61) *60-bit-mask*)) 0))
But the new definition is slightly faster because we avoid the lookup of the *60-bit-mask*.
We could make this almost twice as fast by redefining it under the hood as
Function:
(defun 60-bit-fix$inline (x) (declare (xargs :guard t)) (let ((__function__ '60-bit-fix)) (declare (ignorable __function__)) (if (integerp x) (the (signed-byte 61) (logand x (- (ash 1 60) 1))) 0)))