Fixing function for vl-genblob structures.
(vl-genblob-fix x) → new-x
Function:
(defun vl-genblob-fix$inline (x) (declare (xargs :guard (vl-genblob-p x))) (let ((__function__ 'vl-genblob-fix)) (declare (ignorable __function__)) (mbe :logic (b* ((portdecls (vl-portdecllist-fix (std::prod-car (std::prod-car (std::prod-car (std::prod-car (std::prod-car (cdr x)))))))) (assigns (vl-assignlist-fix (std::prod-cdr (std::prod-car (std::prod-car (std::prod-car (std::prod-car (cdr x)))))))) (aliases (vl-aliaslist-fix (std::prod-car (std::prod-cdr (std::prod-car (std::prod-car (std::prod-car (cdr x)))))))) (vardecls (vl-vardecllist-fix (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-car (std::prod-car (cdr x)))))))) (paramdecls (vl-paramdecllist-fix (std::prod-car (std::prod-car (std::prod-cdr (std::prod-car (std::prod-car (cdr x)))))))) (fundecls (vl-fundecllist-fix (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-car (std::prod-car (cdr x)))))))) (taskdecls (vl-taskdecllist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-car (cdr x)))))))) (modinsts (vl-modinstlist-fix (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-car (cdr x)))))))) (gateinsts (vl-gateinstlist-fix (std::prod-car (std::prod-car (std::prod-car (std::prod-cdr (std::prod-car (cdr x)))))))) (alwayses (vl-alwayslist-fix (std::prod-cdr (std::prod-car (std::prod-car (std::prod-cdr (std::prod-car (cdr x)))))))) (initials (vl-initiallist-fix (std::prod-car (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-car (cdr x)))))))) (finals (vl-finallist-fix (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-car (cdr x)))))))) (typedefs (vl-typedeflist-fix (std::prod-car (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-car (cdr x)))))))) (imports (vl-importlist-fix (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-car (cdr x)))))))) (fwdtypedefs (vl-fwdtypedeflist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (cdr x)))))))) (modports (vl-modportlist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (cdr x))))))))) (genvars (vl-genvarlist-fix (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (cdr x))))))))) (assertions (vl-assertionlist-fix (std::prod-car (std::prod-car (std::prod-car (std::prod-car (std::prod-cdr (cdr x)))))))) (cassertions (vl-cassertionlist-fix (std::prod-cdr (std::prod-car (std::prod-car (std::prod-car (std::prod-cdr (cdr x)))))))) (properties (vl-propertylist-fix (std::prod-car (std::prod-cdr (std::prod-car (std::prod-car (std::prod-cdr (cdr x)))))))) (sequences (vl-sequencelist-fix (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-car (std::prod-cdr (cdr x)))))))) (clkdecls (vl-clkdecllist-fix (std::prod-car (std::prod-car (std::prod-cdr (std::prod-car (std::prod-cdr (cdr x)))))))) (gclkdecls (vl-gclkdecllist-fix (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-car (std::prod-cdr (cdr x)))))))) (defaultdisables (vl-defaultdisablelist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-cdr (cdr x)))))))) (dpiimports (vl-dpiimportlist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-cdr (cdr x))))))))) (dpiexports (vl-dpiexportlist-fix (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-cdr (cdr x))))))))) (binds (vl-bindlist-fix (std::prod-car (std::prod-car (std::prod-car (std::prod-cdr (std::prod-cdr (cdr x)))))))) (classes (vl-classlist-fix (std::prod-cdr (std::prod-car (std::prod-car (std::prod-cdr (std::prod-cdr (cdr x)))))))) (covergroups (vl-covergrouplist-fix (std::prod-car (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-cdr (cdr x)))))))) (elabtasks (vl-elabtasklist-fix (std::prod-cdr (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-cdr (cdr x)))))))) (letdecls (vl-letdecllist-fix (std::prod-car (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (cdr x)))))))) (generates (vl-genelementlist-fix (std::prod-cdr (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (cdr x)))))))) (ports (vl-portlist-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (cdr x)))))))) (scopetype (vl-scopetype-fix (std::prod-car (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (cdr x))))))))) (id (vl-maybe-scopeid-fix (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (std::prod-cdr (cdr x)))))))))) (cons :vl-genblob (std::prod-cons (std::prod-cons (std::prod-cons (std::prod-cons (std::prod-cons portdecls assigns) (std::prod-cons aliases vardecls)) (std::prod-cons (std::prod-cons paramdecls fundecls) (std::prod-cons taskdecls modinsts))) (std::prod-cons (std::prod-cons (std::prod-cons gateinsts alwayses) (std::prod-cons initials finals)) (std::prod-cons (std::prod-cons typedefs imports) (std::prod-cons fwdtypedefs (std::prod-cons modports genvars))))) (std::prod-cons (std::prod-cons (std::prod-cons (std::prod-cons assertions cassertions) (std::prod-cons properties sequences)) (std::prod-cons (std::prod-cons clkdecls gclkdecls) (std::prod-cons defaultdisables (std::prod-cons dpiimports dpiexports)))) (std::prod-cons (std::prod-cons (std::prod-cons binds classes) (std::prod-cons covergroups elabtasks)) (std::prod-cons (std::prod-cons letdecls generates) (std::prod-cons ports (std::prod-cons scopetype id)))))))) :exec x)))
Theorem:
(defthm vl-genblob-p-of-vl-genblob-fix (b* ((new-x (vl-genblob-fix$inline x))) (vl-genblob-p new-x)) :rule-classes :rewrite)
Theorem:
(defthm vl-genblob-fix-when-vl-genblob-p (implies (vl-genblob-p x) (equal (vl-genblob-fix x) x)))
Function:
(defun vl-genblob-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (vl-genblob-p acl2::x) (vl-genblob-p acl2::y)))) (equal (vl-genblob-fix acl2::x) (vl-genblob-fix acl2::y)))
Theorem:
(defthm vl-genblob-equiv-is-an-equivalence (and (booleanp (vl-genblob-equiv x y)) (vl-genblob-equiv x x) (implies (vl-genblob-equiv x y) (vl-genblob-equiv y x)) (implies (and (vl-genblob-equiv x y) (vl-genblob-equiv y z)) (vl-genblob-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm vl-genblob-equiv-implies-equal-vl-genblob-fix-1 (implies (vl-genblob-equiv acl2::x x-equiv) (equal (vl-genblob-fix acl2::x) (vl-genblob-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm vl-genblob-fix-under-vl-genblob-equiv (vl-genblob-equiv (vl-genblob-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-vl-genblob-fix-1-forward-to-vl-genblob-equiv (implies (equal (vl-genblob-fix acl2::x) acl2::y) (vl-genblob-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-vl-genblob-fix-2-forward-to-vl-genblob-equiv (implies (equal acl2::x (vl-genblob-fix acl2::y)) (vl-genblob-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-genblob-equiv-of-vl-genblob-fix-1-forward (implies (vl-genblob-equiv (vl-genblob-fix acl2::x) acl2::y) (vl-genblob-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm vl-genblob-equiv-of-vl-genblob-fix-2-forward (implies (vl-genblob-equiv acl2::x (vl-genblob-fix acl2::y)) (vl-genblob-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)