• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • 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
        • Svstmt
          • Svstmt-case
          • Svstmt-while
          • Svstmt-p
          • Svstmt-if
          • Svstmt-equiv
          • Svstmt-xcond
            • Make-svstmt-xcond
            • Svstmt-xcond->cond
              • Svstmt-xcond->body
              • Change-svstmt-xcond
            • Svstmt-scope
            • Svstmt-assign
            • Svstmt-compile
            • Svstmt-constraints
            • Svstmt-jump
            • Svstmtlist
            • Svstmt-kind
            • Svstmt.lisp
            • Svstmt-fix
            • Svstmt-count
          • Sv-tutorial
          • Expressions
          • Symbolic-test-vector
          • Vl-to-svex
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Svstmt-xcond

    Svstmt-xcond->cond

    Get the cond field from a svstmt-xcond.

    Signature
    (svstmt-xcond->cond x) → cond
    Arguments
    x — Guard (svstmt-p x).
    Returns
    cond — Type (svex-p cond).

    This is an ordinary field accessor created by defprod.

    Definitions and Theorems

    Function: svstmt-xcond->cond$inline

    (defun svstmt-xcond->cond$inline (x)
      (declare (xargs :guard (svstmt-p x)))
      (declare (xargs :guard (equal (svstmt-kind x) :xcond)))
      (let ((__function__ 'svstmt-xcond->cond))
        (declare (ignorable __function__))
        (mbe :logic
             (b* ((x (and (equal (svstmt-kind x) :xcond) x)))
               (svex-fix (std::da-nth 0 (cdr x))))
             :exec (std::da-nth 0 (cdr x)))))

    Theorem: svex-p-of-svstmt-xcond->cond

    (defthm svex-p-of-svstmt-xcond->cond
      (b* ((cond (svstmt-xcond->cond$inline x)))
        (svex-p cond))
      :rule-classes :rewrite)

    Theorem: svstmt-xcond->cond$inline-of-svstmt-fix-x

    (defthm svstmt-xcond->cond$inline-of-svstmt-fix-x
      (equal (svstmt-xcond->cond$inline (svstmt-fix x))
             (svstmt-xcond->cond$inline x)))

    Theorem: svstmt-xcond->cond$inline-svstmt-equiv-congruence-on-x

    (defthm svstmt-xcond->cond$inline-svstmt-equiv-congruence-on-x
      (implies (svstmt-equiv x x-equiv)
               (equal (svstmt-xcond->cond$inline x)
                      (svstmt-xcond->cond$inline x-equiv)))
      :rule-classes :congruence)

    Theorem: svstmt-xcond->cond-when-wrong-kind

    (defthm svstmt-xcond->cond-when-wrong-kind
      (implies (not (equal (svstmt-kind x) :xcond))
               (equal (svstmt-xcond->cond x)
                      (svex-fix nil))))