• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
      • Sv
        • Svex-stvs
        • Svex-decomposition-methodology
        • Sv-versus-esim
        • Svex-decomp
        • Svex-compose-dfs
        • Svex-compilation
        • Moddb
        • Svmods
        • Svstmt
        • Sv-tutorial
        • Expressions
          • Rewriting
            • Svex-rewrite
            • Svexlist-rewrite-nrev
            • Svex-args-apply-masks
            • 4veclist-quote
            • Svex-simpconfig-p
            • Svex-rewrite-memo-correct
            • Svex-alist-maybe-rewrite-fixpoint
            • Svexlist-compute-masks
            • Svexlist-rewrite-under-masks
            • Svex-alist-rewrite-fixpoint
            • Svexlist-maybe-rewrite-fixpoint
            • Svexlist-rewrite-fixpoint
            • Svexlist-mask-acons
            • Svexlist-mask-alist/toposort
            • Svex-call-simp
            • Svex-alist-compose
            • Svexlist-rewrite-top
            • Svex-alist-subst
            • Svex-alist-compose-rw
            • Svex-argmasks-lookup
            • Svex-alist-subst-rw
            • Svexlist-mask-acons-rev
            • Svex-mask-lookup
            • Svex-mask-acons
            • Svexlist-mask-alist
            • Svex-alist-rewrite-top
            • Constraintlist-compose
            • Svex-substconfig
            • Svex-simpconfig-fix
            • Svex-subst
            • Svex-rewrite-memo-vars-ok
              • Svex-norm-call
              • Svex-3value-mask
              • Svexlist-count-calls-aux
              • Svex-mask-alist-keys
              • Rewriter-tracing
              • Svex-rewrite-top
              • Svexlist-maskfree-rewrite-nrev
              • Svexlist-multirefs-top
              • Svexlist-count-calls
              • Svex-unify
              • Svexlist-toposort-p
              • Svexlist-maskfree-rewrite-top
              • Svex-alist-compose-nrev
              • Rewriting-concatenations
              • Svex-svex-memo
              • Svex-mask-alist
              • Svex-alist-subst-nrev
              • Svex-simpconfig-fix!
              • Svex-rewrite-rules
            • Svex
            • Bit-blasting
            • Functions
            • 4vmask
            • Why-infinite-width
            • Svex-vars
            • Evaluation
            • Values
          • Symbolic-test-vector
          • Vl-to-svex
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Rewriting

    Svex-rewrite-memo-vars-ok

    Signature
    (svex-rewrite-memo-vars-ok x var) → *
    Arguments
    x — Guard (svex-svex-memo-p x).

    Definitions and Theorems

    Function: svex-rewrite-memo-vars-ok

    (defun svex-rewrite-memo-vars-ok (x var)
      (declare (xargs :guard (svex-svex-memo-p x)))
      (let ((__function__ 'svex-rewrite-memo-vars-ok))
        (declare (ignorable __function__))
        (ec-call (svex-rewrite-memo-vars-ok1 (svex-svex-memo-fix x)
                                             var))))

    Theorem: svex-rewrite-memo-vars-ok-of-empty

    (defthm svex-rewrite-memo-vars-ok-of-empty
      (implies (atom atom)
               (svex-rewrite-memo-vars-ok atom var))
      :rule-classes ((:rewrite :backchain-limit-lst 0)))

    Theorem: svex-rewrite-memo-vars-ok-implies

    (defthm svex-rewrite-memo-vars-ok-implies
      (implies (svex-rewrite-memo-vars-ok x var)
               (b* ((x (svex-svex-memo-fix x))
                    (lookup (hons-assoc-equal key x))
                    (val (cdr lookup)))
                 (implies (and lookup
                               (not (member var (svex-vars key))))
                          (not (member var (svex-vars val)))))))

    Theorem: svex-rewrite-memo-vars-ok-of-svex-svex-memo-fix-x

    (defthm svex-rewrite-memo-vars-ok-of-svex-svex-memo-fix-x
      (equal (svex-rewrite-memo-vars-ok (svex-svex-memo-fix x)
                                        var)
             (svex-rewrite-memo-vars-ok x var)))

    Theorem: svex-rewrite-memo-vars-ok-svex-svex-memo-equiv-congruence-on-x

    (defthm
         svex-rewrite-memo-vars-ok-svex-svex-memo-equiv-congruence-on-x
      (implies (svex-svex-memo-equiv x x-equiv)
               (equal (svex-rewrite-memo-vars-ok x var)
                      (svex-rewrite-memo-vars-ok x-equiv var)))
      :rule-classes :congruence)

    Theorem: svex-rewrite-memo-vars-ok-cons-1

    (defthm svex-rewrite-memo-vars-ok-cons-1
      (implies (and (svex-rewrite-memo-vars-ok x var)
                    (member var (svex-vars y)))
               (svex-rewrite-memo-vars-ok (cons (cons y y1) x)
                                          var)))

    Theorem: svex-rewrite-memo-vars-ok-cons-2

    (defthm svex-rewrite-memo-vars-ok-cons-2
      (implies (and (svex-rewrite-memo-vars-ok x var)
                    (not (member var (svex-vars y1))))
               (svex-rewrite-memo-vars-ok (cons (cons y y1) x)
                                          var)))