Access the |X86ISA|::|AC| field of a tlb-key bit structure.
Function:
(defun tlb-key->ac$inline (x) (declare (xargs :guard (tlb-key-p x))) (mbe :logic (let ((x (tlb-key-fix x))) (part-select x :low 3 :width 1)) :exec (the (unsigned-byte 1) (logand (the (unsigned-byte 1) 1) (the (unsigned-byte 43) (ash (the (unsigned-byte 46) x) -3))))))
Theorem:
(defthm bitp-of-tlb-key->ac (b* ((ac (tlb-key->ac$inline x))) (bitp ac)) :rule-classes :rewrite)
Theorem:
(defthm tlb-key->ac$inline-of-tlb-key-fix-x (equal (tlb-key->ac$inline (tlb-key-fix x)) (tlb-key->ac$inline x)))
Theorem:
(defthm tlb-key->ac$inline-tlb-key-equiv-congruence-on-x (implies (tlb-key-equiv x x-equiv) (equal (tlb-key->ac$inline x) (tlb-key->ac$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm tlb-key->ac-of-tlb-key (equal (tlb-key->ac (tlb-key wp smep smap ac nxe implicit-supervisor-access r-w-x cpl vpn)) (bfix ac)))
Theorem:
(defthm tlb-key->ac-of-write-with-mask (implies (and (fty::bitstruct-read-over-write-hyps x tlb-key-equiv-under-mask) (tlb-key-equiv-under-mask x y fty::mask) (equal (logand (lognot fty::mask) 8) 0)) (equal (tlb-key->ac x) (tlb-key->ac y))))