Update the |X86ISA|::|FPU/MMX-STATE| field of a xcr0bits bit structure.
(!xcr0bits->fpu/mmx-state fpu/mmx-state x) → new-x
Function:
(defun !xcr0bits->fpu/mmx-state$inline (fpu/mmx-state x) (declare (xargs :guard (and (bitp fpu/mmx-state) (xcr0bits-p x)))) (mbe :logic (b* ((fpu/mmx-state (mbe :logic (bfix fpu/mmx-state) :exec fpu/mmx-state)) (x (xcr0bits-fix x))) (part-install fpu/mmx-state x :width 1 :low 0)) :exec (the (unsigned-byte 64) (logior (the (unsigned-byte 64) (logand (the (unsigned-byte 64) x) (the (signed-byte 2) -2))) (the (unsigned-byte 1) fpu/mmx-state)))))
Theorem:
(defthm xcr0bits-p-of-!xcr0bits->fpu/mmx-state (b* ((new-x (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x))) (xcr0bits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !xcr0bits->fpu/mmx-state$inline-of-bfix-fpu/mmx-state (equal (!xcr0bits->fpu/mmx-state$inline (bfix fpu/mmx-state) x) (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x)))
Theorem:
(defthm !xcr0bits->fpu/mmx-state$inline-bit-equiv-congruence-on-fpu/mmx-state (implies (bit-equiv fpu/mmx-state fpu/mmx-state-equiv) (equal (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x) (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !xcr0bits->fpu/mmx-state$inline-of-xcr0bits-fix-x (equal (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state (xcr0bits-fix x)) (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x)))
Theorem:
(defthm !xcr0bits->fpu/mmx-state$inline-xcr0bits-equiv-congruence-on-x (implies (xcr0bits-equiv x x-equiv) (equal (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x) (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !xcr0bits->fpu/mmx-state-is-xcr0bits (equal (!xcr0bits->fpu/mmx-state fpu/mmx-state x) (change-xcr0bits x :fpu/mmx-state fpu/mmx-state)))
Theorem:
(defthm xcr0bits->fpu/mmx-state-of-!xcr0bits->fpu/mmx-state (b* ((?new-x (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x))) (equal (xcr0bits->fpu/mmx-state new-x) (bfix fpu/mmx-state))))
Theorem:
(defthm !xcr0bits->fpu/mmx-state-equiv-under-mask (b* ((?new-x (!xcr0bits->fpu/mmx-state$inline fpu/mmx-state x))) (xcr0bits-equiv-under-mask new-x x -2)))