Update the |X86ISA|::|S| field of a call-gate-descriptorbits bit structure.
(!call-gate-descriptorbits->s s x) → new-x
Function:
(defun !call-gate-descriptorbits->s$inline (s x) (declare (xargs :guard (and (bitp s) (call-gate-descriptorbits-p x)))) (mbe :logic (b* ((s (mbe :logic (bfix s) :exec s)) (x (call-gate-descriptorbits-fix x))) (part-install s x :width 1 :low 44)) :exec (the (unsigned-byte 128) (logior (the (unsigned-byte 128) (logand (the (unsigned-byte 128) x) (the (signed-byte 46) -17592186044417))) (the (unsigned-byte 45) (ash (the (unsigned-byte 1) s) 44))))))
Theorem:
(defthm call-gate-descriptorbits-p-of-!call-gate-descriptorbits->s (b* ((new-x (!call-gate-descriptorbits->s$inline s x))) (call-gate-descriptorbits-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm !call-gate-descriptorbits->s$inline-of-bfix-s (equal (!call-gate-descriptorbits->s$inline (bfix s) x) (!call-gate-descriptorbits->s$inline s x)))
Theorem:
(defthm !call-gate-descriptorbits->s$inline-bit-equiv-congruence-on-s (implies (bit-equiv s s-equiv) (equal (!call-gate-descriptorbits->s$inline s x) (!call-gate-descriptorbits->s$inline s-equiv x))) :rule-classes :congruence)
Theorem:
(defthm !call-gate-descriptorbits->s$inline-of-call-gate-descriptorbits-fix-x (equal (!call-gate-descriptorbits->s$inline s (call-gate-descriptorbits-fix x)) (!call-gate-descriptorbits->s$inline s x)))
Theorem:
(defthm !call-gate-descriptorbits->s$inline-call-gate-descriptorbits-equiv-congruence-on-x (implies (call-gate-descriptorbits-equiv x x-equiv) (equal (!call-gate-descriptorbits->s$inline s x) (!call-gate-descriptorbits->s$inline s x-equiv))) :rule-classes :congruence)
Theorem:
(defthm !call-gate-descriptorbits->s-is-call-gate-descriptorbits (equal (!call-gate-descriptorbits->s s x) (change-call-gate-descriptorbits x :s s)))
Theorem:
(defthm call-gate-descriptorbits->s-of-!call-gate-descriptorbits->s (b* ((?new-x (!call-gate-descriptorbits->s$inline s x))) (equal (call-gate-descriptorbits->s new-x) (bfix s))))
Theorem:
(defthm !call-gate-descriptorbits->s-equiv-under-mask (b* ((?new-x (!call-gate-descriptorbits->s$inline s x))) (call-gate-descriptorbits-equiv-under-mask new-x x -17592186044417)))