(svex-select-split-static x) → (mv staticp dynamic-part static-part)
Function:
(defun svex-select-split-static (x) (declare (xargs :guard (svex-select-p x))) (let ((__function__ 'svex-select-split-static)) (declare (ignorable __function__)) (svex-select-case x :var (mv t (svex-select-var *svex-longest-static-prefix-var* x.width) (svex-select-fix x)) :part (b* (((mv rest-staticp rest-dyn rest-stat) (svex-select-split-static x.subexp)) ((when (and rest-staticp (svex-case x.lsb :quote (4vec-index-p x.lsb.val) :otherwise nil))) (mv t (svex-select-var *svex-longest-static-prefix-var* x.width) (change-svex-select-part x :subexp rest-stat)))) (mv nil (change-svex-select-part x :subexp rest-dyn) rest-stat)))))
Theorem:
(defthm return-type-of-svex-select-split-static.staticp (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (equal staticp (svex-select-staticp x))) :rule-classes :rewrite)
Theorem:
(defthm svex-select-p-of-svex-select-split-static.dynamic-part (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (svex-select-p dynamic-part)) :rule-classes :rewrite)
Theorem:
(defthm svex-select-p-of-svex-select-split-static.static-part (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (svex-select-p static-part)) :rule-classes :rewrite)
Theorem:
(defthm svex-select-inner-var-of-split-static (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (and (equal (svex-select-inner-var dynamic-part) *svex-longest-static-prefix-var*) (equal (svex-select-inner-var static-part) (svex-select-inner-var x)))))
Theorem:
(defthm svex-select-split-static-dynamic-type-when-staticp (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (implies staticp (equal (svex-select-kind dynamic-part) :var))))
Theorem:
(defthm svex-selects-merge-of-split-static (b* (((mv ?staticp ?dynamic-part ?static-part) (svex-select-split-static x))) (equal (svex-selects-merge dynamic-part static-part) (svex-select-fix x))))
Theorem:
(defthm svex-select-split-static-of-svex-select-fix-x (equal (svex-select-split-static (svex-select-fix x)) (svex-select-split-static x)))
Theorem:
(defthm svex-select-split-static-svex-select-equiv-congruence-on-x (implies (svex-select-equiv x x-equiv) (equal (svex-select-split-static x) (svex-select-split-static x-equiv))) :rule-classes :congruence)