Update the |ACL2|::|Z| field of a evex-byte3 bit structure.
(!evex-byte3->z z x) → new-x
Function:
(defun !evex-byte3->z$inline (z x) (declare (xargs :guard (and (bitp z) (evex-byte3-p x)))) (mbe :logic (b* ((z (mbe :logic (bfix z) :exec z)) (x (evex-byte3-fix x))) (part-install z x :width 1 :low 7)) :exec (the (unsigned-byte 8) (logior (the (unsigned-byte 8) (logand (the (unsigned-byte 8) x) (the (signed-byte 9) -129))) (the (unsigned-byte 8) (ash (the (unsigned-byte 1) z) 7))))))
Theorem:
(defthm evex-byte3-p-of-!evex-byte3->z (b* ((new-x (!evex-byte3->z$inline z x))) (evex-byte3-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !evex-byte3->z$inline-of-bfix-z (equal (!evex-byte3->z$inline (bfix z) x) (!evex-byte3->z$inline z x)))
Theorem:
(defthm !evex-byte3->z$inline-bit-equiv-congruence-on-z (implies (bit-equiv z z-equiv) (equal (!evex-byte3->z$inline z x) (!evex-byte3->z$inline z-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !evex-byte3->z$inline-of-evex-byte3-fix-x (equal (!evex-byte3->z$inline z (evex-byte3-fix x)) (!evex-byte3->z$inline z x)))
Theorem:
(defthm !evex-byte3->z$inline-evex-byte3-equiv-congruence-on-x (implies (evex-byte3-equiv x x-equiv) (equal (!evex-byte3->z$inline z x) (!evex-byte3->z$inline z x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !evex-byte3->z-is-evex-byte3 (equal (!evex-byte3->z z x) (change-evex-byte3 x :z z)))
Theorem:
(defthm evex-byte3->z-of-!evex-byte3->z (b* ((?new-x (!evex-byte3->z$inline z x))) (equal (evex-byte3->z new-x) (bfix z))))
Theorem:
(defthm !evex-byte3->z-equiv-under-mask (b* ((?new-x (!evex-byte3->z$inline z x))) (evex-byte3-equiv-under-mask new-x x 127)))