(rvm128 addr x86) → (mv * * x86)
Function:
(defun rvm128$inline (addr x86) (declare (xargs :stobjs (x86))) (declare (type (signed-byte 48) addr)) (if (mbt (canonical-address-p addr)) (let* ((8+addr (the (signed-byte 49) (+ 8 (the (signed-byte 48) addr)))) (15+addr (the (signed-byte 49) (+ 15 (the (signed-byte 48) addr))))) (if (mbe :logic (canonical-address-p 15+addr) :exec (< (the (signed-byte 49) 15+addr) 140737488355328)) (b* (((mv flg0 (the (unsigned-byte 64) qword0) x86) (rvm64 addr x86)) ((mv flg1 (the (unsigned-byte 64) qword1) x86) (rvm64 8+addr x86)) ((the (unsigned-byte 128) oword) (the (unsigned-byte 128) (logior (the (unsigned-byte 128) (ash qword1 64)) qword0)))) (mbe :logic (if (or flg0 flg1) (mv 'rvm128 0 x86) (mv nil oword x86)) :exec (mv nil oword x86))) (mv 'rvm128 0 x86))) (mv 'rvm128 0 x86)))
Theorem:
(defthm rvm128-no-error (implies (and (canonical-address-p addr) (canonical-address-p (+ 15 addr))) (equal (mv-nth 0 (rvm128 addr x86)) nil)))
Theorem:
(defthm n128p-mv-nth-1-rvm128 (unsigned-byte-p 128 (mv-nth 1 (rvm128 addr x86))) :rule-classes (:rewrite (:type-prescription :corollary (natp (mv-nth 1 (rvm128 addr x86))) :hints (("Goal" :in-theory '(unsigned-byte-p integer-range-p natp)))) (:linear :corollary (and (<= 0 (mv-nth 1 (rvm128 addr x86))) (< (mv-nth 1 (rvm128 addr x86)) 340282366920938463463374607431768211456)) :hints (("Goal" :in-theory '(unsigned-byte-p integer-range-p (:e expt)))))))
Theorem:
(defthm x86p-mv-nth-2-rvm128-unchanged (equal (mv-nth 2 (rvm128 addr x86)) x86))
Theorem:
(defthm xr-rvm128 (equal (xr fld index (mv-nth 2 (rvm128 addr x86))) (xr fld index x86)))
Theorem:
(defthm rvm128-xw-values (implies (not (equal fld :mem)) (and (equal (mv-nth 0 (rvm128 addr (xw fld index value x86))) (mv-nth 0 (rvm128 addr x86))) (equal (mv-nth 1 (rvm128 addr (xw fld index value x86))) (mv-nth 1 (rvm128 addr x86))))))