• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
        • Warnings
        • Primitives
        • Use-set
        • Syntax
        • Getting-started
        • Utilities
        • Loader
        • Transforms
          • Expression-sizing
          • Occform
          • Oprewrite
          • Expand-functions
          • Delayredux
          • Unparameterization
          • Caseelim
          • Split
          • Selresolve
          • Weirdint-elim
          • Vl-delta
          • Replicate-insts
          • Rangeresolve
          • Propagate
          • Clean-selects
          • Clean-params
          • Blankargs
          • Inline-mods
          • Expr-simp
            • Vl-plainarglist-simp
            • Vl-modinstlist-simp
            • Vl-modulelist-simp
            • Vl-assignlist-simp
            • Vl-expr-simp-unary-bitnot
            • Vl-expr-simp-binary-bitor
            • Vl-expr-simp-binary-bitand
            • Vl-expr-simp-qmark
            • Vl-modinst-simp
              • Vl-plainarg-simp
              • Vl-module-simp
              • Vl-design-simp
              • Vl-assign-simp
              • Vl-expr-simp
            • Trunc
            • Always-top
            • Gatesplit
            • Gate-elim
            • Expression-optimization
            • Elim-supplies
            • Wildelim
            • Drop-blankports
            • Clean-warnings
            • Addinstnames
            • Custom-transform-hooks
            • Annotate
            • Latchcode
            • Elim-unused-vars
            • Problem-modules
          • Lint
          • Mlib
          • Server
          • Kit
          • Printer
          • Esim-vl
          • Well-formedness
        • Sv
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Expr-simp

    Vl-modinst-simp

    Signature
    (vl-modinst-simp x) → new-x
    Arguments
    x — Guard (vl-modinst-p x).
    Returns
    new-x — Type (vl-modinst-p new-x).

    Definitions and Theorems

    Function: vl-modinst-simp

    (defun vl-modinst-simp (x)
      (declare (xargs :guard (vl-modinst-p x)))
      (let ((__function__ 'vl-modinst-simp))
        (declare (ignorable __function__))
        (b* ((x (vl-modinst-fix x))
             ((vl-modinst x) x))
          (vl-arguments-case
               x.portargs :vl-arguments-named
               x :vl-arguments-plain
               (b* ((plainargs (vl-plainarglist-simp x.portargs.args))
                    (args (make-vl-arguments-plain :args plainargs)))
                 (change-vl-modinst x
                                    :portargs args))))))

    Theorem: vl-modinst-p-of-vl-modinst-simp

    (defthm vl-modinst-p-of-vl-modinst-simp
      (b* ((new-x (vl-modinst-simp x)))
        (vl-modinst-p new-x))
      :rule-classes :rewrite)

    Theorem: vl-modinst-simp-of-vl-modinst-fix-x

    (defthm vl-modinst-simp-of-vl-modinst-fix-x
      (equal (vl-modinst-simp (vl-modinst-fix x))
             (vl-modinst-simp x)))

    Theorem: vl-modinst-simp-vl-modinst-equiv-congruence-on-x

    (defthm vl-modinst-simp-vl-modinst-equiv-congruence-on-x
      (implies (vl-modinst-equiv x x-equiv)
               (equal (vl-modinst-simp x)
                      (vl-modinst-simp x-equiv)))
      :rule-classes :congruence)