• 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
        • Svstmt
        • Sv-tutorial
        • Expressions
          • Rewriting
          • Svex
          • Bit-blasting
          • Functions
          • 4vmask
            • Svex-argmasks
            • 4vmask-p
            • 4vmask-subsumes
            • 4veclist-mask
            • 4vec-mask-to-zero
            • 4vec-mask
            • 4vmasklist-subsumes
            • 4vmask-union
            • 4vec-mask?
            • 4vmask-equiv
              • 4vmask-fix
              • 4vmask-alist
              • 4veclist-mask?
              • 4vmasklist
              • 4vmask-empty
            • Why-infinite-width
            • Svex-vars
            • Evaluation
            • Values
          • Symbolic-test-vector
          • Vl-to-svex
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • 4vmask

    4vmask-equiv

    Equivalence up to 4vmask-fix.

    Definitions and Theorems

    Function: 4vmask-equiv$inline

    (defun 4vmask-equiv$inline (x y)
      (declare (xargs :guard (and (4vmask-p x) (4vmask-p y))))
      (equal (4vmask-fix x) (4vmask-fix y)))

    Theorem: 4vmask-equiv-is-an-equivalence

    (defthm 4vmask-equiv-is-an-equivalence
      (and (booleanp (4vmask-equiv x y))
           (4vmask-equiv x x)
           (implies (4vmask-equiv x y)
                    (4vmask-equiv y x))
           (implies (and (4vmask-equiv x y)
                         (4vmask-equiv y z))
                    (4vmask-equiv x z)))
      :rule-classes (:equivalence))

    Theorem: 4vmask-equiv-implies-equal-4vmask-fix-1

    (defthm 4vmask-equiv-implies-equal-4vmask-fix-1
      (implies (4vmask-equiv x x-equiv)
               (equal (4vmask-fix x)
                      (4vmask-fix x-equiv)))
      :rule-classes (:congruence))

    Theorem: 4vmask-fix-under-4vmask-equiv

    (defthm 4vmask-fix-under-4vmask-equiv
      (4vmask-equiv (4vmask-fix x) x)
      :rule-classes (:rewrite :rewrite-quoted-constant))

    Theorem: equal-of-4vmask-fix-1-forward-to-4vmask-equiv

    (defthm equal-of-4vmask-fix-1-forward-to-4vmask-equiv
      (implies (equal (4vmask-fix x) y)
               (4vmask-equiv x y))
      :rule-classes :forward-chaining)

    Theorem: equal-of-4vmask-fix-2-forward-to-4vmask-equiv

    (defthm equal-of-4vmask-fix-2-forward-to-4vmask-equiv
      (implies (equal x (4vmask-fix y))
               (4vmask-equiv x y))
      :rule-classes :forward-chaining)

    Theorem: 4vmask-equiv-of-4vmask-fix-1-forward

    (defthm 4vmask-equiv-of-4vmask-fix-1-forward
      (implies (4vmask-equiv (4vmask-fix x) y)
               (4vmask-equiv x y))
      :rule-classes :forward-chaining)

    Theorem: 4vmask-equiv-of-4vmask-fix-2-forward

    (defthm 4vmask-equiv-of-4vmask-fix-2-forward
      (implies (4vmask-equiv x (4vmask-fix y))
               (4vmask-equiv x y))
      :rule-classes :forward-chaining)