Update the |X86ISA|::|LCK| field of a prefixes bit structure.
(!prefixes->lck lck x) → new-x
Function:
(defun !prefixes->lck$inline (lck x) (declare (xargs :guard (and (8bits-p lck) (prefixes-p x)))) (mbe :logic (b* ((lck (mbe :logic (8bits-fix lck) :exec lck)) (x (prefixes-fix x))) (part-install lck x :width 8 :low 4)) :exec (the (unsigned-byte 52) (logior (the (unsigned-byte 52) (logand (the (unsigned-byte 52) x) (the (signed-byte 13) -4081))) (the (unsigned-byte 12) (ash (the (unsigned-byte 8) lck) 4))))))
Theorem:
(defthm prefixes-p-of-!prefixes->lck (b* ((new-x (!prefixes->lck$inline lck x))) (prefixes-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !prefixes->lck$inline-of-8bits-fix-lck (equal (!prefixes->lck$inline (8bits-fix lck) x) (!prefixes->lck$inline lck x)))
Theorem:
(defthm !prefixes->lck$inline-8bits-equiv-congruence-on-lck (implies (8bits-equiv lck lck-equiv) (equal (!prefixes->lck$inline lck x) (!prefixes->lck$inline lck-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !prefixes->lck$inline-of-prefixes-fix-x (equal (!prefixes->lck$inline lck (prefixes-fix x)) (!prefixes->lck$inline lck x)))
Theorem:
(defthm !prefixes->lck$inline-prefixes-equiv-congruence-on-x (implies (prefixes-equiv x x-equiv) (equal (!prefixes->lck$inline lck x) (!prefixes->lck$inline lck x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !prefixes->lck-is-prefixes (equal (!prefixes->lck lck x) (change-prefixes x :lck lck)))
Theorem:
(defthm prefixes->lck-of-!prefixes->lck (b* ((?new-x (!prefixes->lck$inline lck x))) (equal (prefixes->lck new-x) (8bits-fix lck))))
Theorem:
(defthm !prefixes->lck-equiv-under-mask (b* ((?new-x (!prefixes->lck$inline lck x))) (prefixes-equiv-under-mask new-x x -4081)))