Update the |X86ISA|::|OSXSAVE| field of a cr4bits bit structure.
Function:
(defun !cr4bits->osxsave$inline (osxsave x) (declare (xargs :guard (and (bitp osxsave) (cr4bits-p x)))) (mbe :logic (b* ((osxsave (mbe :logic (bfix osxsave) :exec osxsave)) (x (cr4bits-fix x))) (part-install osxsave x :width 1 :low 18)) :exec (the (unsigned-byte 26) (logior (the (unsigned-byte 26) (logand (the (unsigned-byte 26) x) (the (signed-byte 20) -262145))) (the (unsigned-byte 19) (ash (the (unsigned-byte 1) osxsave) 18))))))
Theorem:
(defthm cr4bits-p-of-!cr4bits->osxsave (b* ((new-x (!cr4bits->osxsave$inline osxsave x))) (cr4bits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !cr4bits->osxsave$inline-of-bfix-osxsave (equal (!cr4bits->osxsave$inline (bfix osxsave) x) (!cr4bits->osxsave$inline osxsave x)))
Theorem:
(defthm !cr4bits->osxsave$inline-bit-equiv-congruence-on-osxsave (implies (bit-equiv osxsave osxsave-equiv) (equal (!cr4bits->osxsave$inline osxsave x) (!cr4bits->osxsave$inline osxsave-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !cr4bits->osxsave$inline-of-cr4bits-fix-x (equal (!cr4bits->osxsave$inline osxsave (cr4bits-fix x)) (!cr4bits->osxsave$inline osxsave x)))
Theorem:
(defthm !cr4bits->osxsave$inline-cr4bits-equiv-congruence-on-x (implies (cr4bits-equiv x x-equiv) (equal (!cr4bits->osxsave$inline osxsave x) (!cr4bits->osxsave$inline osxsave x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !cr4bits->osxsave-is-cr4bits (equal (!cr4bits->osxsave osxsave x) (change-cr4bits x :osxsave osxsave)))
Theorem:
(defthm cr4bits->osxsave-of-!cr4bits->osxsave (b* ((?new-x (!cr4bits->osxsave$inline osxsave x))) (equal (cr4bits->osxsave new-x) (bfix osxsave))))
Theorem:
(defthm !cr4bits->osxsave-equiv-under-mask (b* ((?new-x (!cr4bits->osxsave$inline osxsave x))) (cr4bits-equiv-under-mask new-x x -262145)))