• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
      • Sv
      • Fgl
      • Vwsim
      • Vl
        • Syntax
        • Loader
        • Warnings
        • Getting-started
        • Utilities
        • Printer
        • Kit
        • Mlib
        • Transforms
          • Unparameterization
          • Elaborate
          • Addnames
          • Annotate
            • Increment-elim
            • Make-implicit-wires
            • Basic-bind-elim
              • Vl-modulelist-apply-binddelta
              • Vl-interfacelist-apply-binddelta
              • Vl-bindelim-main
              • Vl-bindelim-bindlist
              • Vl-bindelim-find-global-target
              • Vl-interfacelist-bindelim
              • Vl-modulelist-bindelim
              • Vl-interface-bindelim
              • Vl-module-bindelim
              • Vl-bindelim-institem
                • Vl-bindelim-institem-fix
                  • Vl-bindelim-institem-equiv
                  • Make-vl-bindelim-institem
                  • Vl-bindelim-institem->inst
                  • Vl-bindelim-institem->ctx
                  • Vl-bindelim-institem->bindp
                  • Vl-bindelim-institem->genp
                  • Change-vl-bindelim-institem
                  • Vl-bindelim-institem-p
                • Vl-warn-bindintentlist-undefined
                • Vl-warn-bindintent-undefined
                • Vl-interfacelist-bindelim-insttable
                • Vl-modulelist-bindelim-insttable
                • Vl-warn-binddelta-undefined
                • Vl-interface-bindelim-insttable
                • Vl-interface-apply-binddelta
                • Vl-design-bindelim-pass2
                • Vl-bindelim-modinstlist-add-atts
                • Vl-module-bindelim-insttable
                • Vl-module-apply-binddelta
                • Vl-bindelim-modinst-add-atts
                • Vl-design-bindelim-pass1
                • Vl-bindcontext
                • Vl-bindintent->modinsts
                • Vl-bindelim-insttable
                • Vl-bindintentlist->modinsts
                • Vl-binddelta
                • Vl-design-bindelim
                • Vl-bindelim-institemlist
              • Argresolve
              • Basicsanity
              • Portdecl-sign
              • Enum-names
              • Port-resolve
              • Udp-elim
              • Vl-annotate-design
              • Vl-annotate-module
            • Clean-warnings
            • Eliminitial
            • Custom-transform-hooks
            • Problem-modules
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Vl-bindelim-institem

    Vl-bindelim-institem-fix

    Fixing function for vl-bindelim-institem structures.

    Signature
    (vl-bindelim-institem-fix x) → new-x
    Arguments
    x — Guard (vl-bindelim-institem-p x).
    Returns
    new-x — Type (vl-bindelim-institem-p new-x).

    Definitions and Theorems

    Function: vl-bindelim-institem-fix$inline

    (defun vl-bindelim-institem-fix$inline (x)
     (declare (xargs :guard (vl-bindelim-institem-p x)))
     (let ((__function__ 'vl-bindelim-institem-fix))
      (declare (ignorable __function__))
      (mbe
        :logic
        (b*
          ((inst (vl-modinst-fix (std::prod-car (std::prod-car x))))
           (genp (acl2::bool-fix (std::prod-cdr (std::prod-car x))))
           (bindp (acl2::bool-fix (std::prod-car (std::prod-cdr x))))
           (ctx (vl-bindcontext-fix (std::prod-cdr (std::prod-cdr x)))))
          (std::prod-cons (std::prod-cons inst genp)
                          (std::prod-cons bindp ctx)))
        :exec x)))

    Theorem: vl-bindelim-institem-p-of-vl-bindelim-institem-fix

    (defthm vl-bindelim-institem-p-of-vl-bindelim-institem-fix
      (b* ((new-x (vl-bindelim-institem-fix$inline x)))
        (vl-bindelim-institem-p new-x))
      :rule-classes :rewrite)

    Theorem: vl-bindelim-institem-fix-when-vl-bindelim-institem-p

    (defthm vl-bindelim-institem-fix-when-vl-bindelim-institem-p
      (implies (vl-bindelim-institem-p x)
               (equal (vl-bindelim-institem-fix x) x)))

    Function: vl-bindelim-institem-equiv$inline

    (defun vl-bindelim-institem-equiv$inline (acl2::x acl2::y)
      (declare (xargs :guard (and (vl-bindelim-institem-p acl2::x)
                                  (vl-bindelim-institem-p acl2::y))))
      (equal (vl-bindelim-institem-fix acl2::x)
             (vl-bindelim-institem-fix acl2::y)))

    Theorem: vl-bindelim-institem-equiv-is-an-equivalence

    (defthm vl-bindelim-institem-equiv-is-an-equivalence
      (and (booleanp (vl-bindelim-institem-equiv x y))
           (vl-bindelim-institem-equiv x x)
           (implies (vl-bindelim-institem-equiv x y)
                    (vl-bindelim-institem-equiv y x))
           (implies (and (vl-bindelim-institem-equiv x y)
                         (vl-bindelim-institem-equiv y z))
                    (vl-bindelim-institem-equiv x z)))
      :rule-classes (:equivalence))

    Theorem: vl-bindelim-institem-equiv-implies-equal-vl-bindelim-institem-fix-1

    (defthm
     vl-bindelim-institem-equiv-implies-equal-vl-bindelim-institem-fix-1
     (implies (vl-bindelim-institem-equiv acl2::x x-equiv)
              (equal (vl-bindelim-institem-fix acl2::x)
                     (vl-bindelim-institem-fix x-equiv)))
     :rule-classes (:congruence))

    Theorem: vl-bindelim-institem-fix-under-vl-bindelim-institem-equiv

    (defthm vl-bindelim-institem-fix-under-vl-bindelim-institem-equiv
      (vl-bindelim-institem-equiv (vl-bindelim-institem-fix acl2::x)
                                  acl2::x)
      :rule-classes (:rewrite :rewrite-quoted-constant))

    Theorem: equal-of-vl-bindelim-institem-fix-1-forward-to-vl-bindelim-institem-equiv

    (defthm
     equal-of-vl-bindelim-institem-fix-1-forward-to-vl-bindelim-institem-equiv
     (implies (equal (vl-bindelim-institem-fix acl2::x)
                     acl2::y)
              (vl-bindelim-institem-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: equal-of-vl-bindelim-institem-fix-2-forward-to-vl-bindelim-institem-equiv

    (defthm
     equal-of-vl-bindelim-institem-fix-2-forward-to-vl-bindelim-institem-equiv
     (implies (equal acl2::x
                     (vl-bindelim-institem-fix acl2::y))
              (vl-bindelim-institem-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: vl-bindelim-institem-equiv-of-vl-bindelim-institem-fix-1-forward

    (defthm
       vl-bindelim-institem-equiv-of-vl-bindelim-institem-fix-1-forward
     (implies
          (vl-bindelim-institem-equiv (vl-bindelim-institem-fix acl2::x)
                                      acl2::y)
          (vl-bindelim-institem-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: vl-bindelim-institem-equiv-of-vl-bindelim-institem-fix-2-forward

    (defthm
       vl-bindelim-institem-equiv-of-vl-bindelim-institem-fix-2-forward
     (implies
         (vl-bindelim-institem-equiv acl2::x
                                     (vl-bindelim-institem-fix acl2::y))
         (vl-bindelim-institem-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)