Fixing function for vl-cycledelayrange structures.
(vl-cycledelayrange-fix x) → new-x
Function:
(defun vl-cycledelayrange-fix$inline (x) (declare (xargs :guard (vl-cycledelayrange-p x))) (let ((__function__ 'vl-cycledelayrange-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((left (vl-expr-fix (std::prod-car (cdr x)))) (right (vl-maybe-expr-fix (std::prod-cdr (cdr x))))) (cons :vl-cycledelayrange (std::prod-cons left right))) :exec x)))
Theorem:
(defthm vl-cycledelayrange-p-of-vl-cycledelayrange-fix (b* ((new-x (vl-cycledelayrange-fix$inline x))) (vl-cycledelayrange-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-cycledelayrange-fix-when-vl-cycledelayrange-p (implies (vl-cycledelayrange-p x) (equal (vl-cycledelayrange-fix x) x)))
Function:
(defun vl-cycledelayrange-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (vl-cycledelayrange-p acl2::x) (vl-cycledelayrange-p acl2::y)))) (equal (vl-cycledelayrange-fix acl2::x) (vl-cycledelayrange-fix acl2::y)))
Theorem:
(defthm vl-cycledelayrange-equiv-is-an-equivalence (and (booleanp (vl-cycledelayrange-equiv x y)) (vl-cycledelayrange-equiv x x) (implies (vl-cycledelayrange-equiv x y) (vl-cycledelayrange-equiv y x)) (implies (and (vl-cycledelayrange-equiv x y) (vl-cycledelayrange-equiv y z)) (vl-cycledelayrange-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm vl-cycledelayrange-equiv-implies-equal-vl-cycledelayrange-fix-1 (implies (vl-cycledelayrange-equiv acl2::x x-equiv) (equal (vl-cycledelayrange-fix acl2::x) (vl-cycledelayrange-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm vl-cycledelayrange-fix-under-vl-cycledelayrange-equiv (vl-cycledelayrange-equiv (vl-cycledelayrange-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-vl-cycledelayrange-fix-1-forward-to-vl-cycledelayrange-equiv (implies (equal (vl-cycledelayrange-fix acl2::x) acl2::y) (vl-cycledelayrange-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-vl-cycledelayrange-fix-2-forward-to-vl-cycledelayrange-equiv (implies (equal acl2::x (vl-cycledelayrange-fix acl2::y)) (vl-cycledelayrange-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-cycledelayrange-equiv-of-vl-cycledelayrange-fix-1-forward (implies (vl-cycledelayrange-equiv (vl-cycledelayrange-fix acl2::x) acl2::y) (vl-cycledelayrange-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-cycledelayrange-equiv-of-vl-cycledelayrange-fix-2-forward (implies (vl-cycledelayrange-equiv acl2::x (vl-cycledelayrange-fix acl2::y)) (vl-cycledelayrange-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)