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