• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • 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
          • Address
          • Wire
          • Module
          • Lhs
            • Lhs.lisp
            • Lhs-p
            • Lhs-fix
            • Lhrange
            • Lhs-eval-zx
            • Lhs-equiv
            • Lhs-eval
            • Lhs->svex
            • Path
            • Svar-add-namespace
            • Design
            • Modinst
            • Lhs-add-namespace
            • Modalist
            • Path-add-namespace
            • Modname->submodnames
            • Name
            • Constraintlist-addr-p
            • Svex-alist-addr-p
            • Svar-map-addr-p
            • Lhspairs-addr-p
            • Modname
            • Assigns-addr-p
            • Lhs-addr-p
            • Lhatom-addr-p
            • Modhier-list-measure
            • Attributes
            • Modhier-measure
            • Modhier-list-measure-aux
            • Modhier-loopfreelist-p
            • Modhier-loopfree-p
          • Svstmt
          • Sv-tutorial
          • Expressions
          • Symbolic-test-vector
          • Vl-to-svex
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Lhs

    Lhs->svex

    Signature
    (lhs->svex x) → xx
    Arguments
    x — Guard (lhs-p x).
    Returns
    xx — Type (svex-p xx).

    Definitions and Theorems

    Function: lhs->svex

    (defun lhs->svex (x)
      (declare (xargs :guard (lhs-p x)))
      (let ((__function__ 'lhs->svex))
        (declare (ignorable __function__))
        (if (atom x)
            (svex-quote (4vec-z))
          (b* (((lhrange xf) (car x)))
            (svex-concat xf.w (lhatom->svex xf.atom)
                         (lhs->svex (cdr x)))))))

    Theorem: svex-p-of-lhs->svex

    (defthm svex-p-of-lhs->svex
      (b* ((xx (lhs->svex x))) (svex-p xx))
      :rule-classes :rewrite)

    Theorem: lhs->svex-of-lhs-fix-x

    (defthm lhs->svex-of-lhs-fix-x
      (equal (lhs->svex (lhs-fix x))
             (lhs->svex x)))

    Theorem: lhs->svex-lhs-equiv-congruence-on-x

    (defthm lhs->svex-lhs-equiv-congruence-on-x
      (implies (lhs-equiv x x-equiv)
               (equal (lhs->svex x)
                      (lhs->svex x-equiv)))
      :rule-classes :congruence)

    Theorem: lhs->svex-correct

    (defthm lhs->svex-correct
      (equal (svex-eval (lhs->svex x) env)
             (lhs-eval x env)))

    Theorem: vars-of-lhs->svex

    (defthm vars-of-lhs->svex
      (implies (not (member v (lhs-vars x)))
               (not (member v (svex-vars (lhs->svex x))))))