The x87 FPU Status Register.
This is a bitstruct type introduced by defbitstruct, represented as a unsigned 16-bit integer.
Source: Intel Manual, Dec-23, Vol. 1, Section 8.1.3.
Function:
(defun fp-statusbits-p (x) (declare (xargs :guard t)) (let ((__function__ 'fp-statusbits-p)) (declare (ignorable __function__)) (mbe :logic (unsigned-byte-p 16 x) :exec (and (natp x) (< x 65536)))))
Theorem:
(defthm fp-statusbits-p-when-unsigned-byte-p (implies (unsigned-byte-p 16 x) (fp-statusbits-p x)))
Theorem:
(defthm unsigned-byte-p-when-fp-statusbits-p (implies (fp-statusbits-p x) (unsigned-byte-p 16 x)))
Theorem:
(defthm fp-statusbits-p-compound-recognizer (implies (fp-statusbits-p x) (natp x)) :rule-classes :compound-recognizer)
Function:
(defun fp-statusbits-fix (x) (declare (xargs :guard (fp-statusbits-p x))) (let ((__function__ 'fp-statusbits-fix)) (declare (ignorable __function__)) (mbe :logic (loghead 16 x) :exec x)))
Theorem:
(defthm fp-statusbits-p-of-fp-statusbits-fix (b* ((fty::fixed (fp-statusbits-fix x))) (fp-statusbits-p fty::fixed)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits-fix-when-fp-statusbits-p (implies (fp-statusbits-p x) (equal (fp-statusbits-fix x) x)))
Function:
(defun fp-statusbits-equiv$inline (x y) (declare (xargs :guard (and (fp-statusbits-p x) (fp-statusbits-p y)))) (equal (fp-statusbits-fix x) (fp-statusbits-fix y)))
Theorem:
(defthm fp-statusbits-equiv-is-an-equivalence (and (booleanp (fp-statusbits-equiv x y)) (fp-statusbits-equiv x x) (implies (fp-statusbits-equiv x y) (fp-statusbits-equiv y x)) (implies (and (fp-statusbits-equiv x y) (fp-statusbits-equiv y z)) (fp-statusbits-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm fp-statusbits-equiv-implies-equal-fp-statusbits-fix-1 (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits-fix x) (fp-statusbits-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm fp-statusbits-fix-under-fp-statusbits-equiv (fp-statusbits-equiv (fp-statusbits-fix x) x) :rule-classes (:rewrite :rewrite-quoted-constant))
Function:
(defun fp-statusbits (ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (declare (xargs :guard (and (bitp ie) (bitp de) (bitp ze) (bitp oe) (bitp ue) (bitp pe) (bitp sf) (bitp es) (bitp c0) (bitp c1) (bitp c2) (3bits-p top) (bitp c3) (bitp b)))) (let ((__function__ 'fp-statusbits)) (declare (ignorable __function__)) (b* ((ie (mbe :logic (bfix ie) :exec ie)) (de (mbe :logic (bfix de) :exec de)) (ze (mbe :logic (bfix ze) :exec ze)) (oe (mbe :logic (bfix oe) :exec oe)) (ue (mbe :logic (bfix ue) :exec ue)) (pe (mbe :logic (bfix pe) :exec pe)) (sf (mbe :logic (bfix sf) :exec sf)) (es (mbe :logic (bfix es) :exec es)) (c0 (mbe :logic (bfix c0) :exec c0)) (c1 (mbe :logic (bfix c1) :exec c1)) (c2 (mbe :logic (bfix c2) :exec c2)) (top (mbe :logic (3bits-fix top) :exec top)) (c3 (mbe :logic (bfix c3) :exec c3)) (b (mbe :logic (bfix b) :exec b))) (logapp 1 ie (logapp 1 de (logapp 1 ze (logapp 1 oe (logapp 1 ue (logapp 1 pe (logapp 1 sf (logapp 1 es (logapp 1 c0 (logapp 1 c1 (logapp 1 c2 (logapp 3 top (logapp 1 c3 b))))))))))))))))
Theorem:
(defthm fp-statusbits-p-of-fp-statusbits (b* ((fp-statusbits (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b))) (fp-statusbits-p fp-statusbits)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits-of-bfix-ie (equal (fp-statusbits (bfix ie) de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-ie (implies (bit-equiv ie ie-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie-equiv de ze oe ue pe sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-de (equal (fp-statusbits ie (bfix de) ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-de (implies (bit-equiv de de-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de-equiv ze oe ue pe sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-ze (equal (fp-statusbits ie de (bfix ze) oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-ze (implies (bit-equiv ze ze-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze-equiv oe ue pe sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-oe (equal (fp-statusbits ie de ze (bfix oe) ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-oe (implies (bit-equiv oe oe-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe-equiv ue pe sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-ue (equal (fp-statusbits ie de ze oe (bfix ue) pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-ue (implies (bit-equiv ue ue-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue-equiv pe sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-pe (equal (fp-statusbits ie de ze oe ue (bfix pe) sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-pe (implies (bit-equiv pe pe-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe-equiv sf es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-sf (equal (fp-statusbits ie de ze oe ue pe (bfix sf) es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-sf (implies (bit-equiv sf sf-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf-equiv es c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-es (equal (fp-statusbits ie de ze oe ue pe sf (bfix es) c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-es (implies (bit-equiv es es-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es-equiv c0 c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-c0 (equal (fp-statusbits ie de ze oe ue pe sf es (bfix c0) c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-c0 (implies (bit-equiv c0 c0-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0-equiv c1 c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-c1 (equal (fp-statusbits ie de ze oe ue pe sf es c0 (bfix c1) c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-c1 (implies (bit-equiv c1 c1-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1-equiv c2 top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-c2 (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 (bfix c2) top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-c2 (implies (bit-equiv c2 c2-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2-equiv top c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-3bits-fix-top (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 (3bits-fix top) c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-3bits-equiv-congruence-on-top (implies (3bits-equiv top top-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top-equiv c3 b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-c3 (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top (bfix c3) b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-c3 (implies (bit-equiv c3 c3-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3-equiv b))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits-of-bfix-b (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 (bfix b)) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)))
Theorem:
(defthm fp-statusbits-bit-equiv-congruence-on-b (implies (bit-equiv b b-equiv) (equal (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b) (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b-equiv))) :rule-classes :congruence)
Function:
(defun fp-statusbits-equiv-under-mask (x x1 mask) (declare (xargs :guard (and (fp-statusbits-p x) (fp-statusbits-p x1) (integerp mask)))) (let ((__function__ 'fp-statusbits-equiv-under-mask)) (declare (ignorable __function__)) (fty::int-equiv-under-mask (fp-statusbits-fix x) (fp-statusbits-fix x1) mask)))
Function:
(defun fp-statusbits->ie$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 0 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 16) x)))))
Theorem:
(defthm bitp-of-fp-statusbits->ie (b* ((ie (fp-statusbits->ie$inline x))) (bitp ie)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->ie$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->ie$inline (fp-statusbits-fix x)) (fp-statusbits->ie$inline x)))
Theorem:
(defthm fp-statusbits->ie$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->ie$inline x) (fp-statusbits->ie$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->ie-of-fp-statusbits (equal (fp-statusbits->ie (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix ie)))
Theorem:
(defthm fp-statusbits->ie-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 1) 0)) (equal (fp-statusbits->ie x) (fp-statusbits->ie y))))
Function:
(defun fp-statusbits->de$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 1 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 15) (ash (the (unsigned-byte 16) x) -1))))))
Theorem:
(defthm bitp-of-fp-statusbits->de (b* ((de (fp-statusbits->de$inline x))) (bitp de)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->de$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->de$inline (fp-statusbits-fix x)) (fp-statusbits->de$inline x)))
Theorem:
(defthm fp-statusbits->de$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->de$inline x) (fp-statusbits->de$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->de-of-fp-statusbits (equal (fp-statusbits->de (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix de)))
Theorem:
(defthm fp-statusbits->de-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 2) 0)) (equal (fp-statusbits->de x) (fp-statusbits->de y))))
Function:
(defun fp-statusbits->ze$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 2 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 14) (ash (the (unsigned-byte 16) x) -2))))))
Theorem:
(defthm bitp-of-fp-statusbits->ze (b* ((ze (fp-statusbits->ze$inline x))) (bitp ze)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->ze$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->ze$inline (fp-statusbits-fix x)) (fp-statusbits->ze$inline x)))
Theorem:
(defthm fp-statusbits->ze$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->ze$inline x) (fp-statusbits->ze$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->ze-of-fp-statusbits (equal (fp-statusbits->ze (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix ze)))
Theorem:
(defthm fp-statusbits->ze-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 4) 0)) (equal (fp-statusbits->ze x) (fp-statusbits->ze y))))
Function:
(defun fp-statusbits->oe$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 3 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 13) (ash (the (unsigned-byte 16) x) -3))))))
Theorem:
(defthm bitp-of-fp-statusbits->oe (b* ((oe (fp-statusbits->oe$inline x))) (bitp oe)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->oe$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->oe$inline (fp-statusbits-fix x)) (fp-statusbits->oe$inline x)))
Theorem:
(defthm fp-statusbits->oe$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->oe$inline x) (fp-statusbits->oe$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->oe-of-fp-statusbits (equal (fp-statusbits->oe (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix oe)))
Theorem:
(defthm fp-statusbits->oe-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 8) 0)) (equal (fp-statusbits->oe x) (fp-statusbits->oe y))))
Function:
(defun fp-statusbits->ue$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 4 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 12) (ash (the (unsigned-byte 16) x) -4))))))
Theorem:
(defthm bitp-of-fp-statusbits->ue (b* ((ue (fp-statusbits->ue$inline x))) (bitp ue)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->ue$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->ue$inline (fp-statusbits-fix x)) (fp-statusbits->ue$inline x)))
Theorem:
(defthm fp-statusbits->ue$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->ue$inline x) (fp-statusbits->ue$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->ue-of-fp-statusbits (equal (fp-statusbits->ue (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix ue)))
Theorem:
(defthm fp-statusbits->ue-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 16) 0)) (equal (fp-statusbits->ue x) (fp-statusbits->ue y))))
Function:
(defun fp-statusbits->pe$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 5 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 11) (ash (the (unsigned-byte 16) x) -5))))))
Theorem:
(defthm bitp-of-fp-statusbits->pe (b* ((pe (fp-statusbits->pe$inline x))) (bitp pe)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->pe$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->pe$inline (fp-statusbits-fix x)) (fp-statusbits->pe$inline x)))
Theorem:
(defthm fp-statusbits->pe$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->pe$inline x) (fp-statusbits->pe$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->pe-of-fp-statusbits (equal (fp-statusbits->pe (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix pe)))
Theorem:
(defthm fp-statusbits->pe-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 32) 0)) (equal (fp-statusbits->pe x) (fp-statusbits->pe y))))
Function:
(defun fp-statusbits->sf$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 6 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 10) (ash (the (unsigned-byte 16) x) -6))))))
Theorem:
(defthm bitp-of-fp-statusbits->sf (b* ((sf (fp-statusbits->sf$inline x))) (bitp sf)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->sf$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->sf$inline (fp-statusbits-fix x)) (fp-statusbits->sf$inline x)))
Theorem:
(defthm fp-statusbits->sf$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->sf$inline x) (fp-statusbits->sf$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->sf-of-fp-statusbits (equal (fp-statusbits->sf (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix sf)))
Theorem:
(defthm fp-statusbits->sf-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 64) 0)) (equal (fp-statusbits->sf x) (fp-statusbits->sf y))))
Function:
(defun fp-statusbits->es$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 7 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 9) (ash (the (unsigned-byte 16) x) -7))))))
Theorem:
(defthm bitp-of-fp-statusbits->es (b* ((es (fp-statusbits->es$inline x))) (bitp es)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->es$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->es$inline (fp-statusbits-fix x)) (fp-statusbits->es$inline x)))
Theorem:
(defthm fp-statusbits->es$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->es$inline x) (fp-statusbits->es$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->es-of-fp-statusbits (equal (fp-statusbits->es (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix es)))
Theorem:
(defthm fp-statusbits->es-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 128) 0)) (equal (fp-statusbits->es x) (fp-statusbits->es y))))
Function:
(defun fp-statusbits->c0$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 8 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 8) (ash (the (unsigned-byte 16) x) -8))))))
Theorem:
(defthm bitp-of-fp-statusbits->c0 (b* ((c0 (fp-statusbits->c0$inline x))) (bitp c0)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->c0$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->c0$inline (fp-statusbits-fix x)) (fp-statusbits->c0$inline x)))
Theorem:
(defthm fp-statusbits->c0$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->c0$inline x) (fp-statusbits->c0$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->c0-of-fp-statusbits (equal (fp-statusbits->c0 (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix c0)))
Theorem:
(defthm fp-statusbits->c0-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 256) 0)) (equal (fp-statusbits->c0 x) (fp-statusbits->c0 y))))
Function:
(defun fp-statusbits->c1$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 9 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 7) (ash (the (unsigned-byte 16) x) -9))))))
Theorem:
(defthm bitp-of-fp-statusbits->c1 (b* ((c1 (fp-statusbits->c1$inline x))) (bitp c1)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->c1$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->c1$inline (fp-statusbits-fix x)) (fp-statusbits->c1$inline x)))
Theorem:
(defthm fp-statusbits->c1$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->c1$inline x) (fp-statusbits->c1$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->c1-of-fp-statusbits (equal (fp-statusbits->c1 (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix c1)))
Theorem:
(defthm fp-statusbits->c1-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 512) 0)) (equal (fp-statusbits->c1 x) (fp-statusbits->c1 y))))
Function:
(defun fp-statusbits->c2$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 10 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 6) (ash (the (unsigned-byte 16) x) -10))))))
Theorem:
(defthm bitp-of-fp-statusbits->c2 (b* ((c2 (fp-statusbits->c2$inline x))) (bitp c2)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->c2$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->c2$inline (fp-statusbits-fix x)) (fp-statusbits->c2$inline x)))
Theorem:
(defthm fp-statusbits->c2$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->c2$inline x) (fp-statusbits->c2$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->c2-of-fp-statusbits (equal (fp-statusbits->c2 (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix c2)))
Theorem:
(defthm fp-statusbits->c2-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 1024) 0)) (equal (fp-statusbits->c2 x) (fp-statusbits->c2 y))))
Function:
(defun fp-statusbits->top$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 11 :width 3)) :exec (the (unsigned-byte 3) (logand (the (unsigned-byte 3) 7) (the (unsigned-byte 5) (ash (the (unsigned-byte 16) x) -11))))))
Theorem:
(defthm 3bits-p-of-fp-statusbits->top (b* ((top (fp-statusbits->top$inline x))) (3bits-p top)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->top$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->top$inline (fp-statusbits-fix x)) (fp-statusbits->top$inline x)))
Theorem:
(defthm fp-statusbits->top$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->top$inline x) (fp-statusbits->top$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->top-of-fp-statusbits (equal (fp-statusbits->top (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (3bits-fix top)))
Theorem:
(defthm fp-statusbits->top-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 14336) 0)) (equal (fp-statusbits->top x) (fp-statusbits->top y))))
Function:
(defun fp-statusbits->c3$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 14 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 2) (ash (the (unsigned-byte 16) x) -14))))))
Theorem:
(defthm bitp-of-fp-statusbits->c3 (b* ((c3 (fp-statusbits->c3$inline x))) (bitp c3)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->c3$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->c3$inline (fp-statusbits-fix x)) (fp-statusbits->c3$inline x)))
Theorem:
(defthm fp-statusbits->c3$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->c3$inline x) (fp-statusbits->c3$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->c3-of-fp-statusbits (equal (fp-statusbits->c3 (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix c3)))
Theorem:
(defthm fp-statusbits->c3-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 16384) 0)) (equal (fp-statusbits->c3 x) (fp-statusbits->c3 y))))
Function:
(defun fp-statusbits->b$inline (x) (declare (xargs :guard (fp-statusbits-p x))) (mbe :logic (let ((x (fp-statusbits-fix x))) (part-select x :low 15 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 1) (ash (the (unsigned-byte 16) x) -15))))))
Theorem:
(defthm bitp-of-fp-statusbits->b (b* ((b (fp-statusbits->b$inline x))) (bitp b)) :rule-classes :rewrite)
Theorem:
(defthm fp-statusbits->b$inline-of-fp-statusbits-fix-x (equal (fp-statusbits->b$inline (fp-statusbits-fix x)) (fp-statusbits->b$inline x)))
Theorem:
(defthm fp-statusbits->b$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (fp-statusbits->b$inline x) (fp-statusbits->b$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm fp-statusbits->b-of-fp-statusbits (equal (fp-statusbits->b (fp-statusbits ie de ze oe ue pe sf es c0 c1 c2 top c3 b)) (bfix b)))
Theorem:
(defthm fp-statusbits->b-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x fp-statusbits-equiv-under-mask) (fp-statusbits-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 32768) 0)) (equal (fp-statusbits->b x) (fp-statusbits->b y))))
Theorem:
(defthm fp-statusbits-fix-in-terms-of-fp-statusbits (equal (fp-statusbits-fix x) (change-fp-statusbits x)))
Function:
(defun !fp-statusbits->ie$inline (ie x) (declare (xargs :guard (and (bitp ie) (fp-statusbits-p x)))) (mbe :logic (b* ((ie (mbe :logic (bfix ie) :exec ie)) (x (fp-statusbits-fix x))) (part-install ie x :width 1 :low 0)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 2) -2))) (the (unsigned-byte 1) ie)))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->ie (b* ((new-x (!fp-statusbits->ie$inline ie x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->ie$inline-of-bfix-ie (equal (!fp-statusbits->ie$inline (bfix ie) x) (!fp-statusbits->ie$inline ie x)))
Theorem:
(defthm !fp-statusbits->ie$inline-bit-equiv-congruence-on-ie (implies (bit-equiv ie ie-equiv) (equal (!fp-statusbits->ie$inline ie x) (!fp-statusbits->ie$inline ie-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ie$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->ie$inline ie (fp-statusbits-fix x)) (!fp-statusbits->ie$inline ie x)))
Theorem:
(defthm !fp-statusbits->ie$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->ie$inline ie x) (!fp-statusbits->ie$inline ie x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ie-is-fp-statusbits (equal (!fp-statusbits->ie ie x) (change-fp-statusbits x :ie ie)))
Theorem:
(defthm fp-statusbits->ie-of-!fp-statusbits->ie (b* ((?new-x (!fp-statusbits->ie$inline ie x))) (equal (fp-statusbits->ie new-x) (bfix ie))))
Theorem:
(defthm !fp-statusbits->ie-equiv-under-mask (b* ((?new-x (!fp-statusbits->ie$inline ie x))) (fp-statusbits-equiv-under-mask new-x x -2)))
Function:
(defun !fp-statusbits->de$inline (de x) (declare (xargs :guard (and (bitp de) (fp-statusbits-p x)))) (mbe :logic (b* ((de (mbe :logic (bfix de) :exec de)) (x (fp-statusbits-fix x))) (part-install de x :width 1 :low 1)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 3) -3))) (the (unsigned-byte 2) (ash (the (unsigned-byte 1) de) 1))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->de (b* ((new-x (!fp-statusbits->de$inline de x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->de$inline-of-bfix-de (equal (!fp-statusbits->de$inline (bfix de) x) (!fp-statusbits->de$inline de x)))
Theorem:
(defthm !fp-statusbits->de$inline-bit-equiv-congruence-on-de (implies (bit-equiv de de-equiv) (equal (!fp-statusbits->de$inline de x) (!fp-statusbits->de$inline de-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->de$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->de$inline de (fp-statusbits-fix x)) (!fp-statusbits->de$inline de x)))
Theorem:
(defthm !fp-statusbits->de$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->de$inline de x) (!fp-statusbits->de$inline de x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->de-is-fp-statusbits (equal (!fp-statusbits->de de x) (change-fp-statusbits x :de de)))
Theorem:
(defthm fp-statusbits->de-of-!fp-statusbits->de (b* ((?new-x (!fp-statusbits->de$inline de x))) (equal (fp-statusbits->de new-x) (bfix de))))
Theorem:
(defthm !fp-statusbits->de-equiv-under-mask (b* ((?new-x (!fp-statusbits->de$inline de x))) (fp-statusbits-equiv-under-mask new-x x -3)))
Function:
(defun !fp-statusbits->ze$inline (ze x) (declare (xargs :guard (and (bitp ze) (fp-statusbits-p x)))) (mbe :logic (b* ((ze (mbe :logic (bfix ze) :exec ze)) (x (fp-statusbits-fix x))) (part-install ze x :width 1 :low 2)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 4) -5))) (the (unsigned-byte 3) (ash (the (unsigned-byte 1) ze) 2))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->ze (b* ((new-x (!fp-statusbits->ze$inline ze x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->ze$inline-of-bfix-ze (equal (!fp-statusbits->ze$inline (bfix ze) x) (!fp-statusbits->ze$inline ze x)))
Theorem:
(defthm !fp-statusbits->ze$inline-bit-equiv-congruence-on-ze (implies (bit-equiv ze ze-equiv) (equal (!fp-statusbits->ze$inline ze x) (!fp-statusbits->ze$inline ze-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ze$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->ze$inline ze (fp-statusbits-fix x)) (!fp-statusbits->ze$inline ze x)))
Theorem:
(defthm !fp-statusbits->ze$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->ze$inline ze x) (!fp-statusbits->ze$inline ze x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ze-is-fp-statusbits (equal (!fp-statusbits->ze ze x) (change-fp-statusbits x :ze ze)))
Theorem:
(defthm fp-statusbits->ze-of-!fp-statusbits->ze (b* ((?new-x (!fp-statusbits->ze$inline ze x))) (equal (fp-statusbits->ze new-x) (bfix ze))))
Theorem:
(defthm !fp-statusbits->ze-equiv-under-mask (b* ((?new-x (!fp-statusbits->ze$inline ze x))) (fp-statusbits-equiv-under-mask new-x x -5)))
Function:
(defun !fp-statusbits->oe$inline (oe x) (declare (xargs :guard (and (bitp oe) (fp-statusbits-p x)))) (mbe :logic (b* ((oe (mbe :logic (bfix oe) :exec oe)) (x (fp-statusbits-fix x))) (part-install oe x :width 1 :low 3)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 5) -9))) (the (unsigned-byte 4) (ash (the (unsigned-byte 1) oe) 3))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->oe (b* ((new-x (!fp-statusbits->oe$inline oe x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->oe$inline-of-bfix-oe (equal (!fp-statusbits->oe$inline (bfix oe) x) (!fp-statusbits->oe$inline oe x)))
Theorem:
(defthm !fp-statusbits->oe$inline-bit-equiv-congruence-on-oe (implies (bit-equiv oe oe-equiv) (equal (!fp-statusbits->oe$inline oe x) (!fp-statusbits->oe$inline oe-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->oe$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->oe$inline oe (fp-statusbits-fix x)) (!fp-statusbits->oe$inline oe x)))
Theorem:
(defthm !fp-statusbits->oe$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->oe$inline oe x) (!fp-statusbits->oe$inline oe x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->oe-is-fp-statusbits (equal (!fp-statusbits->oe oe x) (change-fp-statusbits x :oe oe)))
Theorem:
(defthm fp-statusbits->oe-of-!fp-statusbits->oe (b* ((?new-x (!fp-statusbits->oe$inline oe x))) (equal (fp-statusbits->oe new-x) (bfix oe))))
Theorem:
(defthm !fp-statusbits->oe-equiv-under-mask (b* ((?new-x (!fp-statusbits->oe$inline oe x))) (fp-statusbits-equiv-under-mask new-x x -9)))
Function:
(defun !fp-statusbits->ue$inline (ue x) (declare (xargs :guard (and (bitp ue) (fp-statusbits-p x)))) (mbe :logic (b* ((ue (mbe :logic (bfix ue) :exec ue)) (x (fp-statusbits-fix x))) (part-install ue x :width 1 :low 4)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 6) -17))) (the (unsigned-byte 5) (ash (the (unsigned-byte 1) ue) 4))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->ue (b* ((new-x (!fp-statusbits->ue$inline ue x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->ue$inline-of-bfix-ue (equal (!fp-statusbits->ue$inline (bfix ue) x) (!fp-statusbits->ue$inline ue x)))
Theorem:
(defthm !fp-statusbits->ue$inline-bit-equiv-congruence-on-ue (implies (bit-equiv ue ue-equiv) (equal (!fp-statusbits->ue$inline ue x) (!fp-statusbits->ue$inline ue-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ue$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->ue$inline ue (fp-statusbits-fix x)) (!fp-statusbits->ue$inline ue x)))
Theorem:
(defthm !fp-statusbits->ue$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->ue$inline ue x) (!fp-statusbits->ue$inline ue x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->ue-is-fp-statusbits (equal (!fp-statusbits->ue ue x) (change-fp-statusbits x :ue ue)))
Theorem:
(defthm fp-statusbits->ue-of-!fp-statusbits->ue (b* ((?new-x (!fp-statusbits->ue$inline ue x))) (equal (fp-statusbits->ue new-x) (bfix ue))))
Theorem:
(defthm !fp-statusbits->ue-equiv-under-mask (b* ((?new-x (!fp-statusbits->ue$inline ue x))) (fp-statusbits-equiv-under-mask new-x x -17)))
Function:
(defun !fp-statusbits->pe$inline (pe x) (declare (xargs :guard (and (bitp pe) (fp-statusbits-p x)))) (mbe :logic (b* ((pe (mbe :logic (bfix pe) :exec pe)) (x (fp-statusbits-fix x))) (part-install pe x :width 1 :low 5)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 7) -33))) (the (unsigned-byte 6) (ash (the (unsigned-byte 1) pe) 5))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->pe (b* ((new-x (!fp-statusbits->pe$inline pe x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->pe$inline-of-bfix-pe (equal (!fp-statusbits->pe$inline (bfix pe) x) (!fp-statusbits->pe$inline pe x)))
Theorem:
(defthm !fp-statusbits->pe$inline-bit-equiv-congruence-on-pe (implies (bit-equiv pe pe-equiv) (equal (!fp-statusbits->pe$inline pe x) (!fp-statusbits->pe$inline pe-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->pe$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->pe$inline pe (fp-statusbits-fix x)) (!fp-statusbits->pe$inline pe x)))
Theorem:
(defthm !fp-statusbits->pe$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->pe$inline pe x) (!fp-statusbits->pe$inline pe x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->pe-is-fp-statusbits (equal (!fp-statusbits->pe pe x) (change-fp-statusbits x :pe pe)))
Theorem:
(defthm fp-statusbits->pe-of-!fp-statusbits->pe (b* ((?new-x (!fp-statusbits->pe$inline pe x))) (equal (fp-statusbits->pe new-x) (bfix pe))))
Theorem:
(defthm !fp-statusbits->pe-equiv-under-mask (b* ((?new-x (!fp-statusbits->pe$inline pe x))) (fp-statusbits-equiv-under-mask new-x x -33)))
Function:
(defun !fp-statusbits->sf$inline (sf x) (declare (xargs :guard (and (bitp sf) (fp-statusbits-p x)))) (mbe :logic (b* ((sf (mbe :logic (bfix sf) :exec sf)) (x (fp-statusbits-fix x))) (part-install sf x :width 1 :low 6)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 8) -65))) (the (unsigned-byte 7) (ash (the (unsigned-byte 1) sf) 6))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->sf (b* ((new-x (!fp-statusbits->sf$inline sf x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->sf$inline-of-bfix-sf (equal (!fp-statusbits->sf$inline (bfix sf) x) (!fp-statusbits->sf$inline sf x)))
Theorem:
(defthm !fp-statusbits->sf$inline-bit-equiv-congruence-on-sf (implies (bit-equiv sf sf-equiv) (equal (!fp-statusbits->sf$inline sf x) (!fp-statusbits->sf$inline sf-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->sf$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->sf$inline sf (fp-statusbits-fix x)) (!fp-statusbits->sf$inline sf x)))
Theorem:
(defthm !fp-statusbits->sf$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->sf$inline sf x) (!fp-statusbits->sf$inline sf x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->sf-is-fp-statusbits (equal (!fp-statusbits->sf sf x) (change-fp-statusbits x :sf sf)))
Theorem:
(defthm fp-statusbits->sf-of-!fp-statusbits->sf (b* ((?new-x (!fp-statusbits->sf$inline sf x))) (equal (fp-statusbits->sf new-x) (bfix sf))))
Theorem:
(defthm !fp-statusbits->sf-equiv-under-mask (b* ((?new-x (!fp-statusbits->sf$inline sf x))) (fp-statusbits-equiv-under-mask new-x x -65)))
Function:
(defun !fp-statusbits->es$inline (es x) (declare (xargs :guard (and (bitp es) (fp-statusbits-p x)))) (mbe :logic (b* ((es (mbe :logic (bfix es) :exec es)) (x (fp-statusbits-fix x))) (part-install es x :width 1 :low 7)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 9) -129))) (the (unsigned-byte 8) (ash (the (unsigned-byte 1) es) 7))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->es (b* ((new-x (!fp-statusbits->es$inline es x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->es$inline-of-bfix-es (equal (!fp-statusbits->es$inline (bfix es) x) (!fp-statusbits->es$inline es x)))
Theorem:
(defthm !fp-statusbits->es$inline-bit-equiv-congruence-on-es (implies (bit-equiv es es-equiv) (equal (!fp-statusbits->es$inline es x) (!fp-statusbits->es$inline es-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->es$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->es$inline es (fp-statusbits-fix x)) (!fp-statusbits->es$inline es x)))
Theorem:
(defthm !fp-statusbits->es$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->es$inline es x) (!fp-statusbits->es$inline es x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->es-is-fp-statusbits (equal (!fp-statusbits->es es x) (change-fp-statusbits x :es es)))
Theorem:
(defthm fp-statusbits->es-of-!fp-statusbits->es (b* ((?new-x (!fp-statusbits->es$inline es x))) (equal (fp-statusbits->es new-x) (bfix es))))
Theorem:
(defthm !fp-statusbits->es-equiv-under-mask (b* ((?new-x (!fp-statusbits->es$inline es x))) (fp-statusbits-equiv-under-mask new-x x -129)))
Function:
(defun !fp-statusbits->c0$inline (c0 x) (declare (xargs :guard (and (bitp c0) (fp-statusbits-p x)))) (mbe :logic (b* ((c0 (mbe :logic (bfix c0) :exec c0)) (x (fp-statusbits-fix x))) (part-install c0 x :width 1 :low 8)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 10) -257))) (the (unsigned-byte 9) (ash (the (unsigned-byte 1) c0) 8))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->c0 (b* ((new-x (!fp-statusbits->c0$inline c0 x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->c0$inline-of-bfix-c0 (equal (!fp-statusbits->c0$inline (bfix c0) x) (!fp-statusbits->c0$inline c0 x)))
Theorem:
(defthm !fp-statusbits->c0$inline-bit-equiv-congruence-on-c0 (implies (bit-equiv c0 c0-equiv) (equal (!fp-statusbits->c0$inline c0 x) (!fp-statusbits->c0$inline c0-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c0$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->c0$inline c0 (fp-statusbits-fix x)) (!fp-statusbits->c0$inline c0 x)))
Theorem:
(defthm !fp-statusbits->c0$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->c0$inline c0 x) (!fp-statusbits->c0$inline c0 x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c0-is-fp-statusbits (equal (!fp-statusbits->c0 c0 x) (change-fp-statusbits x :c0 c0)))
Theorem:
(defthm fp-statusbits->c0-of-!fp-statusbits->c0 (b* ((?new-x (!fp-statusbits->c0$inline c0 x))) (equal (fp-statusbits->c0 new-x) (bfix c0))))
Theorem:
(defthm !fp-statusbits->c0-equiv-under-mask (b* ((?new-x (!fp-statusbits->c0$inline c0 x))) (fp-statusbits-equiv-under-mask new-x x -257)))
Function:
(defun !fp-statusbits->c1$inline (c1 x) (declare (xargs :guard (and (bitp c1) (fp-statusbits-p x)))) (mbe :logic (b* ((c1 (mbe :logic (bfix c1) :exec c1)) (x (fp-statusbits-fix x))) (part-install c1 x :width 1 :low 9)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 11) -513))) (the (unsigned-byte 10) (ash (the (unsigned-byte 1) c1) 9))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->c1 (b* ((new-x (!fp-statusbits->c1$inline c1 x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->c1$inline-of-bfix-c1 (equal (!fp-statusbits->c1$inline (bfix c1) x) (!fp-statusbits->c1$inline c1 x)))
Theorem:
(defthm !fp-statusbits->c1$inline-bit-equiv-congruence-on-c1 (implies (bit-equiv c1 c1-equiv) (equal (!fp-statusbits->c1$inline c1 x) (!fp-statusbits->c1$inline c1-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c1$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->c1$inline c1 (fp-statusbits-fix x)) (!fp-statusbits->c1$inline c1 x)))
Theorem:
(defthm !fp-statusbits->c1$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->c1$inline c1 x) (!fp-statusbits->c1$inline c1 x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c1-is-fp-statusbits (equal (!fp-statusbits->c1 c1 x) (change-fp-statusbits x :c1 c1)))
Theorem:
(defthm fp-statusbits->c1-of-!fp-statusbits->c1 (b* ((?new-x (!fp-statusbits->c1$inline c1 x))) (equal (fp-statusbits->c1 new-x) (bfix c1))))
Theorem:
(defthm !fp-statusbits->c1-equiv-under-mask (b* ((?new-x (!fp-statusbits->c1$inline c1 x))) (fp-statusbits-equiv-under-mask new-x x -513)))
Function:
(defun !fp-statusbits->c2$inline (c2 x) (declare (xargs :guard (and (bitp c2) (fp-statusbits-p x)))) (mbe :logic (b* ((c2 (mbe :logic (bfix c2) :exec c2)) (x (fp-statusbits-fix x))) (part-install c2 x :width 1 :low 10)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 12) -1025))) (the (unsigned-byte 11) (ash (the (unsigned-byte 1) c2) 10))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->c2 (b* ((new-x (!fp-statusbits->c2$inline c2 x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->c2$inline-of-bfix-c2 (equal (!fp-statusbits->c2$inline (bfix c2) x) (!fp-statusbits->c2$inline c2 x)))
Theorem:
(defthm !fp-statusbits->c2$inline-bit-equiv-congruence-on-c2 (implies (bit-equiv c2 c2-equiv) (equal (!fp-statusbits->c2$inline c2 x) (!fp-statusbits->c2$inline c2-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c2$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->c2$inline c2 (fp-statusbits-fix x)) (!fp-statusbits->c2$inline c2 x)))
Theorem:
(defthm !fp-statusbits->c2$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->c2$inline c2 x) (!fp-statusbits->c2$inline c2 x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c2-is-fp-statusbits (equal (!fp-statusbits->c2 c2 x) (change-fp-statusbits x :c2 c2)))
Theorem:
(defthm fp-statusbits->c2-of-!fp-statusbits->c2 (b* ((?new-x (!fp-statusbits->c2$inline c2 x))) (equal (fp-statusbits->c2 new-x) (bfix c2))))
Theorem:
(defthm !fp-statusbits->c2-equiv-under-mask (b* ((?new-x (!fp-statusbits->c2$inline c2 x))) (fp-statusbits-equiv-under-mask new-x x -1025)))
Function:
(defun !fp-statusbits->top$inline (top x) (declare (xargs :guard (and (3bits-p top) (fp-statusbits-p x)))) (mbe :logic (b* ((top (mbe :logic (3bits-fix top) :exec top)) (x (fp-statusbits-fix x))) (part-install top x :width 3 :low 11)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 15) -14337))) (the (unsigned-byte 14) (ash (the (unsigned-byte 3) top) 11))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->top (b* ((new-x (!fp-statusbits->top$inline top x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->top$inline-of-3bits-fix-top (equal (!fp-statusbits->top$inline (3bits-fix top) x) (!fp-statusbits->top$inline top x)))
Theorem:
(defthm !fp-statusbits->top$inline-3bits-equiv-congruence-on-top (implies (3bits-equiv top top-equiv) (equal (!fp-statusbits->top$inline top x) (!fp-statusbits->top$inline top-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->top$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->top$inline top (fp-statusbits-fix x)) (!fp-statusbits->top$inline top x)))
Theorem:
(defthm !fp-statusbits->top$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->top$inline top x) (!fp-statusbits->top$inline top x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->top-is-fp-statusbits (equal (!fp-statusbits->top top x) (change-fp-statusbits x :top top)))
Theorem:
(defthm fp-statusbits->top-of-!fp-statusbits->top (b* ((?new-x (!fp-statusbits->top$inline top x))) (equal (fp-statusbits->top new-x) (3bits-fix top))))
Theorem:
(defthm !fp-statusbits->top-equiv-under-mask (b* ((?new-x (!fp-statusbits->top$inline top x))) (fp-statusbits-equiv-under-mask new-x x -14337)))
Function:
(defun !fp-statusbits->c3$inline (c3 x) (declare (xargs :guard (and (bitp c3) (fp-statusbits-p x)))) (mbe :logic (b* ((c3 (mbe :logic (bfix c3) :exec c3)) (x (fp-statusbits-fix x))) (part-install c3 x :width 1 :low 14)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 16) -16385))) (the (unsigned-byte 15) (ash (the (unsigned-byte 1) c3) 14))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->c3 (b* ((new-x (!fp-statusbits->c3$inline c3 x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->c3$inline-of-bfix-c3 (equal (!fp-statusbits->c3$inline (bfix c3) x) (!fp-statusbits->c3$inline c3 x)))
Theorem:
(defthm !fp-statusbits->c3$inline-bit-equiv-congruence-on-c3 (implies (bit-equiv c3 c3-equiv) (equal (!fp-statusbits->c3$inline c3 x) (!fp-statusbits->c3$inline c3-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c3$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->c3$inline c3 (fp-statusbits-fix x)) (!fp-statusbits->c3$inline c3 x)))
Theorem:
(defthm !fp-statusbits->c3$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->c3$inline c3 x) (!fp-statusbits->c3$inline c3 x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->c3-is-fp-statusbits (equal (!fp-statusbits->c3 c3 x) (change-fp-statusbits x :c3 c3)))
Theorem:
(defthm fp-statusbits->c3-of-!fp-statusbits->c3 (b* ((?new-x (!fp-statusbits->c3$inline c3 x))) (equal (fp-statusbits->c3 new-x) (bfix c3))))
Theorem:
(defthm !fp-statusbits->c3-equiv-under-mask (b* ((?new-x (!fp-statusbits->c3$inline c3 x))) (fp-statusbits-equiv-under-mask new-x x -16385)))
Function:
(defun !fp-statusbits->b$inline (b x) (declare (xargs :guard (and (bitp b) (fp-statusbits-p x)))) (mbe :logic (b* ((b (mbe :logic (bfix b) :exec b)) (x (fp-statusbits-fix x))) (part-install b x :width 1 :low 15)) :exec (the (unsigned-byte 16) (logior (the (unsigned-byte 16) (logand (the (unsigned-byte 16) x) (the (signed-byte 17) -32769))) (the (unsigned-byte 16) (ash (the (unsigned-byte 1) b) 15))))))
Theorem:
(defthm fp-statusbits-p-of-!fp-statusbits->b (b* ((new-x (!fp-statusbits->b$inline b x))) (fp-statusbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !fp-statusbits->b$inline-of-bfix-b (equal (!fp-statusbits->b$inline (bfix b) x) (!fp-statusbits->b$inline b x)))
Theorem:
(defthm !fp-statusbits->b$inline-bit-equiv-congruence-on-b (implies (bit-equiv b b-equiv) (equal (!fp-statusbits->b$inline b x) (!fp-statusbits->b$inline b-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->b$inline-of-fp-statusbits-fix-x (equal (!fp-statusbits->b$inline b (fp-statusbits-fix x)) (!fp-statusbits->b$inline b x)))
Theorem:
(defthm !fp-statusbits->b$inline-fp-statusbits-equiv-congruence-on-x (implies (fp-statusbits-equiv x x-equiv) (equal (!fp-statusbits->b$inline b x) (!fp-statusbits->b$inline b x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !fp-statusbits->b-is-fp-statusbits (equal (!fp-statusbits->b b x) (change-fp-statusbits x :b b)))
Theorem:
(defthm fp-statusbits->b-of-!fp-statusbits->b (b* ((?new-x (!fp-statusbits->b$inline b x))) (equal (fp-statusbits->b new-x) (bfix b))))
Theorem:
(defthm !fp-statusbits->b-equiv-under-mask (b* ((?new-x (!fp-statusbits->b$inline b x))) (fp-statusbits-equiv-under-mask new-x x 32767)))
Function:
(defun fp-statusbits-debug (x) (declare (xargs :guard (fp-statusbits-p x))) (let ((__function__ 'fp-statusbits-debug)) (declare (ignorable __function__)) (b* (((fp-statusbits x))) (cons (cons 'ie x.ie) (cons (cons 'de x.de) (cons (cons 'ze x.ze) (cons (cons 'oe x.oe) (cons (cons 'ue x.ue) (cons (cons 'pe x.pe) (cons (cons 'sf x.sf) (cons (cons 'es x.es) (cons (cons 'c0 x.c0) (cons (cons 'c1 x.c1) (cons (cons 'c2 x.c2) (cons (cons 'top x.top) (cons (cons 'c3 x.c3) (cons (cons 'b x.b) nil)))))))))))))))))