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