Fixing function for svjumpstate structures.
(svjumpstate-fix x) → new-x
Function:
(defun svjumpstate-fix$inline (x) (declare (xargs :guard (svjumpstate-p x))) (let ((__function__ 'svjumpstate-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((constraints (constraintlist-fix (cdr (std::da-nth 0 x)))) (breakcond (svex-fix (cdr (std::da-nth 1 x)))) (breakst (svstate-fix (cdr (std::da-nth 2 x)))) (continuecond (svex-fix (cdr (std::da-nth 3 x)))) (continuest (svstate-fix (cdr (std::da-nth 4 x)))) (returncond (svex-fix (cdr (std::da-nth 5 x)))) (returnst (svstate-fix (cdr (std::da-nth 6 x))))) (list (cons 'constraints constraints) (cons 'breakcond breakcond) (cons 'breakst breakst) (cons 'continuecond continuecond) (cons 'continuest continuest) (cons 'returncond returncond) (cons 'returnst returnst))) :exec x)))
Theorem:
(defthm svjumpstate-p-of-svjumpstate-fix (b* ((new-x (svjumpstate-fix$inline x))) (svjumpstate-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm svjumpstate-fix-when-svjumpstate-p (implies (svjumpstate-p x) (equal (svjumpstate-fix x) x)))
Function:
(defun svjumpstate-equiv$inline (x y) (declare (xargs :guard (and (svjumpstate-p x) (svjumpstate-p y)))) (equal (svjumpstate-fix x) (svjumpstate-fix y)))
Theorem:
(defthm svjumpstate-equiv-is-an-equivalence (and (booleanp (svjumpstate-equiv x y)) (svjumpstate-equiv x x) (implies (svjumpstate-equiv x y) (svjumpstate-equiv y x)) (implies (and (svjumpstate-equiv x y) (svjumpstate-equiv y z)) (svjumpstate-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm svjumpstate-equiv-implies-equal-svjumpstate-fix-1 (implies (svjumpstate-equiv x x-equiv) (equal (svjumpstate-fix x) (svjumpstate-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm svjumpstate-fix-under-svjumpstate-equiv (svjumpstate-equiv (svjumpstate-fix x) x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-svjumpstate-fix-1-forward-to-svjumpstate-equiv (implies (equal (svjumpstate-fix x) y) (svjumpstate-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-svjumpstate-fix-2-forward-to-svjumpstate-equiv (implies (equal x (svjumpstate-fix y)) (svjumpstate-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm svjumpstate-equiv-of-svjumpstate-fix-1-forward (implies (svjumpstate-equiv (svjumpstate-fix x) y) (svjumpstate-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm svjumpstate-equiv-of-svjumpstate-fix-2-forward (implies (svjumpstate-equiv x (svjumpstate-fix y)) (svjumpstate-equiv x y)) :rule-classes :forward-chaining)