Optimized implementation of 64-bit sign-extension.
(fast-logext64 x) → *
Function:
(defun fast-logext64$inline (x) (declare (xargs :guard (integerp x))) (let ((__function__ 'fast-logext64)) (declare (ignorable __function__)) (mbe :logic (logext 64 x) :exec (if (and (<= x 1152921504606846975) (<= -1152921504606846976 x)) x (the (signed-byte 64) (- (the (unsigned-byte 64) (logxor (the (unsigned-byte 64) (logand 18446744073709551615 x)) (the (unsigned-byte 64) 9223372036854775808))) 9223372036854775808))))))