(vl-module-gatesplit x) → new-x
Function:
(defun vl-module-gatesplit (x) (declare (xargs :guard (vl-module-p x))) (let ((__function__ 'vl-module-gatesplit)) (declare (ignorable __function__)) (b* (((when (vl-module->hands-offp x)) x) (gateinsts (vl-module->gateinsts x)) (warnings (vl-module->warnings x)) (vardecls (vl-module->vardecls x)) (nf (vl-starting-namefactory x)) ((mv warnings new-decls gates nf) (vl-gateinstlist-gatesplit gateinsts nf warnings)) (- (vl-free-namefactory nf))) (change-vl-module x :vardecls (append new-decls vardecls) :gateinsts gates :warnings warnings))))
Theorem:
(defthm vl-module-p-of-vl-module-gatesplit (implies (and (force (vl-module-p x))) (b* ((new-x (vl-module-gatesplit x))) (vl-module-p new-x))) :rule-classes :rewrite)