Theorem:
(defthm xr-fault-rb-state-in-sys-view (implies (not (mv-nth 0 (las-to-pas n lin-addr r-w-x (double-rewrite x86)))) (equal (xr :fault index (mv-nth 2 (rb n lin-addr r-w-x x86))) (xr :fault index x86))))
Theorem:
(defthm rb-and-xw-flags-state-in-sys-view (implies (and (equal (rflagsbits->ac (double-rewrite value)) (rflagsbits->ac (rflags x86))) (x86p x86)) (equal (mv-nth 2 (rb n lin-addr r-w-x (xw :rflags nil value x86))) (xw :rflags nil value (mv-nth 2 (rb n lin-addr r-w-x x86))))))
Theorem:
(defthm mv-nth-0-rb-and-paging-equiv-memory-cong (implies (paging-equiv-memory x86-1 x86-2) (equal (mv-nth 0 (rb n lin-addr r-w-x x86-1)) (mv-nth 0 (rb n lin-addr r-w-x x86-2)))) :rule-classes :congruence)
Theorem:
(defthm read-from-physical-memory-and-xlate-equiv-memory-disjoint-from-paging-structures-0 (implies (and (bind-free (find-an-xlate-equiv-x86 'read-from-physical-memory-and-xlate-equiv-memory x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (xlate-equiv-memory (double-rewrite x86-1) x86-2) (physical-address-listp p-addrs) (disjoint-p p-addrs (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1))))) (equal (read-from-physical-memory p-addrs x86-1) (read-from-physical-memory p-addrs x86-2))))
Theorem:
(defthm read-from-physical-memory-and-paging-equiv-memory-disjoint-from-paging-structures-0 (implies (and (bind-free (find-an-paging-equiv-x86 'read-from-physical-memory-and-paging-equiv-memory x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (paging-equiv-memory (double-rewrite x86-1) x86-2) (physical-address-listp p-addrs) (disjoint-p p-addrs (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1))))) (equal (read-from-physical-memory p-addrs x86-1) (read-from-physical-memory p-addrs x86-2))))
Theorem:
(defthm read-from-physical-memory-and-xlate-equiv-memory-disjoint-from-paging-structures (implies (and (bind-free (find-an-xlate-equiv-x86 'read-from-physical-memory-and-xlate-equiv-memory x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (xlate-equiv-memory (double-rewrite x86-1) x86-2) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-2))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-2)))) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-1))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1))))) (equal (read-from-physical-memory (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-1)) x86-1) (read-from-physical-memory (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-1)) x86-2))))
Theorem:
(defthm read-from-physical-memory-and-paging-equiv-memory-disjoint-from-paging-structures (implies (and (bind-free (find-an-paging-equiv-x86 'read-from-physical-memory-and-paging-equiv-memory x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (paging-equiv-memory (double-rewrite x86-1) x86-2) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-2))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-2)))) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-1))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1))))) (equal (read-from-physical-memory (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-1)) x86-1) (read-from-physical-memory (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-1)) x86-2))))
Theorem:
(defthm xlate-equiv-memory-tlb-consistent-n-implies-equal-las-to-pas (implies (and (xlate-equiv-memory x86-1 x86-2) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (tlb-consistent-n n lin-addr r-w-x x86-1) (tlb-consistent-n n lin-addr r-w-x x86-2)) (and (equal (mv-nth 0 (las-to-pas n lin-addr r-w-x x86-1)) (mv-nth 0 (las-to-pas n lin-addr r-w-x x86-2))) (equal (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-1)) (mv-nth 1 (las-to-pas n lin-addr r-w-x x86-2))))))
Theorem:
(defthm mv-nth-1-rb-and-xlate-equiv-memory-disjoint-from-paging-structures (implies (and (bind-free (find-an-xlate-equiv-x86 'mv-nth-1-rb-and-xlate-equiv-memory-disjoint-from-paging-structures x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (xlate-equiv-memory (double-rewrite x86-1) x86-2) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-2))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-2)))) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-1))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1)))) (tlb-consistent-n n lin-addr r-w-x x86-1) (tlb-consistent-n n lin-addr r-w-x x86-2) (64-bit-modep (double-rewrite x86-1))) (equal (mv-nth 1 (rb n lin-addr r-w-x x86-1)) (mv-nth 1 (rb n lin-addr r-w-x x86-2)))))
Theorem:
(defthm mv-nth-1-rb-and-paging-equiv-memory-disjoint-from-paging-structures (implies (and (bind-free (find-an-paging-equiv-x86 'mv-nth-1-rb-and-paging-equiv-memory-disjoint-from-paging-structures x86-1 'x86-2 mfc state) (x86-2)) (syntaxp (and (not (eq x86-2 x86-1)) (term-order x86-2 x86-1))) (paging-equiv-memory (double-rewrite x86-1) x86-2) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-2))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-2)))) (disjoint-p (mv-nth 1 (las-to-pas n lin-addr r-w-x (double-rewrite x86-1))) (open-qword-paddr-list (gather-all-paging-structure-qword-addresses (double-rewrite x86-1)))) (64-bit-modep (double-rewrite x86-1))) (equal (mv-nth 1 (rb n lin-addr r-w-x x86-1)) (mv-nth 1 (rb n lin-addr r-w-x x86-2)))))
Theorem:
(defthm mv-nth-2-rb-and-xlate-equiv-memory (implies (and (not (mv-nth 0 (las-to-pas n lin-addr r-w-x (double-rewrite x86)))) (64-bit-modep (double-rewrite x86))) (xlate-equiv-memory (mv-nth 2 (rb n lin-addr r-w-x x86)) (double-rewrite x86))))
Theorem:
(defthm mv-nth-2-rb-and-paging-equiv-memory (implies (and (not (mv-nth 0 (las-to-pas n lin-addr r-w-x (double-rewrite x86)))) (64-bit-modep (double-rewrite x86))) (paging-equiv-memory (mv-nth 2 (rb n lin-addr r-w-x x86)) (double-rewrite x86))))
Theorem:
(defthm mv-nth-1-rb-after-mv-nth-2-rb (implies (and (disjoint-p$ (mv-nth 1 (las-to-pas n-1 lin-addr-1 r-w-x-1 (double-rewrite x86))) (all-xlation-governing-entries-paddrs n-2 lin-addr-2 (double-rewrite x86))) (disjoint-p$ (mv-nth 1 (las-to-pas n-1 lin-addr-1 r-w-x-1 (double-rewrite x86))) (all-xlation-governing-entries-paddrs n-1 lin-addr-1 (double-rewrite x86))) (64-bit-modep (double-rewrite x86))) (equal (mv-nth 1 (rb n-1 lin-addr-1 r-w-x-1 (mv-nth 2 (rb n-2 lin-addr-2 r-w-x-2 x86)))) (mv-nth 1 (rb n-1 lin-addr-1 r-w-x-1 x86)))))
Theorem:
(defthm mv-nth-1-rb-after-mv-nth-2-las-to-pas (implies (and (disjoint-p (mv-nth 1 (las-to-pas n-1 lin-addr-1 r-w-x-1 (double-rewrite x86))) (all-xlation-governing-entries-paddrs n-2 lin-addr-2 (double-rewrite x86))) (disjoint-p (mv-nth 1 (las-to-pas n-1 lin-addr-1 r-w-x-1 (double-rewrite x86))) (all-xlation-governing-entries-paddrs n-1 lin-addr-1 (double-rewrite x86))) (not (app-view x86)) (64-bit-modep (double-rewrite x86))) (equal (mv-nth 1 (rb n-1 lin-addr-1 r-w-x-1 (mv-nth 2 (las-to-pas n-2 lin-addr-2 r-w-x-2 x86)))) (mv-nth 1 (rb n-1 lin-addr-1 r-w-x-1 (double-rewrite x86))))))