• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • ACL2
    • Macro-libraries
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
        • Symbolic-test-vectors
        • Esim-primitives
        • E-conversion
          • Vl-ealist-p
          • Modinsts-to-eoccs
          • Vl-module-make-esim
          • Exploding-vectors
            • Vl-wirealist-p
            • Emodwire-encoding
            • Vl-emodwire-p
              • Vl-emodwire
              • Vl-emodwirelist-highest
              • Vl-emodwire-fix
              • Vl-emodwire->index
              • Vl-emodwire->basename
              • Vl-emodwirelistlist
              • Vl-emodwirelist
            • Resolving-multiple-drivers
            • Vl-modulelist-make-esims
            • Vl-module-check-e-ok
            • Vl-collect-design-wires
            • Adding-z-drivers
            • Vl-design-to-e
            • Vl-design-to-e-check-ports
            • Vl-design-to-e-main
            • Port-bit-checking
          • Esim-steps
          • Patterns
          • Mod-internal-paths
          • Defmodules
          • Esim-simplify-update-fns
          • Esim-tutorial
          • Esim-vl
        • Vl2014
        • Sv
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Vl-emodwire-p

    Vl-emodwire->basename

    Returns the name of an vl-emodwire-p, excluding the index, as a string.

    For instance, the basename of |opcode[3]| is "opcode", and the basename of |reset| is "reset".

    Definitions and Theorems

    Function: vl-emodwire->basename

    (defun vl-emodwire->basename (x)
      (declare (xargs :guard (vl-emodwire-p x)))
      (b* ((name (symbol-name x))
           (open (position #\[ name)))
        (vl-emodwire-decode (if open (subseq name 0 open) name))))

    Theorem: stringp-of-vl-emodwire->basename

    (defthm stringp-of-vl-emodwire->basename
      (stringp (vl-emodwire->basename x))
      :rule-classes :type-prescription)

    Theorem: vl-emodwire->basename-of-vl-emodwire

    (defthm vl-emodwire->basename-of-vl-emodwire
      (implies
           (and (force (stringp basename))
                (force (maybe-natp index)))
           (equal (vl-emodwire->basename (vl-emodwire basename index))
                  basename)))