• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
      • Sv
      • Fgl
      • Vwsim
      • Vl
        • Syntax
        • Loader
        • Warnings
        • Getting-started
        • Utilities
        • Printer
        • Kit
          • Vl-lint
            • Vl-lintconfig-p
            • Condcheck
            • Lint-warning-suppression
            • Lucid
            • Lvaluecheck
            • Vl-interfacelist-alwaysstyle
            • Truncation-warnings
            • Vl-modulelist-alwaysstyle
            • Skip-detection
              • Vl-ctxexprlist->exprs
              • Sd-keylist->indicies
              • Sd-keylist-find-skipped
              • Sd-problem
              • Sd-key
              • Sd-patalist-compare
                • Sd-analyze-ctxexprs
                • Sd-keygen
                • Make-sd-patalist
                • Sd-analyze-modulelist
                • Sd-analyze-module-aux
                • Sd-analyze-module
                • Sd-pp-problem-long
                • Sd-problem-score
                • Sd-pp-problem-header
                • Sd-analyze-modulelist-aux
                • Sd-analyze-design
                • Sd-problem->
                • Sd-patalist
                • Sd-problemlist
                • Sd-pp-problem-brief
                • Sd-keylist
                • Sd-pp-problemlist-long
                • Sd-pp-problemlist-brief
                • Sd-natlist-linear-increments-p
                • Sd-keylist-linear-increments-p
              • Vl-lint-report
              • Vl-lintresult
              • Vl::vl-design-sv-use-set
              • Oddexpr-check
              • Leftright-check
              • Duplicate-detect
              • Selfassigns
              • *vl-lint-help*
              • Arith-compare-check
              • Dupeinst-check
              • Qmarksize-check
              • Lint-whole-file-suppression
              • Run-vl-lint-main
              • Logicassign
              • Run-vl-lint
              • Vl-print-certain-warnings
              • Duperhs-check
              • Vl-lint-top
              • Sd-filter-problems
              • Vl-modulelist-add-svbad-warnings
              • Vl-module-add-svbad-warnings
              • Check-case
              • Vl-lint-extra-actions
              • Drop-lint-stubs
              • Vl-lint-print-warnings
              • Drop-user-submodules
              • Check-namespace
              • Vl-lintconfig-loadconfig
              • Vl-lint-design->svex-modalist-wrapper
              • Vl-delete-sd-problems-for-modnames-aux
              • Vl-collect-new-names-from-orignames
              • Vl-lint-print-all-warnings
              • Vl-design-remove-unnecessary-modules
              • Vl-delete-sd-problems-for-modnames
              • Vl-always-check-style
              • Vl-vardecllist-svbad-warnings
              • Vl-vardecl-svbad-warnings
              • Vl-reportcard-remove-suppressed
              • Vl-reportcard-keep-suppressed
              • Vl-alwayslist-check-style
              • Vl-remove-nameless-descriptions
              • Vl-lint-apply-quiet
              • Vl-warninglist-remove-suppressed
              • Vl-warninglist-keep-suppressed
              • Vl-print-eliminated-descs
              • Vl-module-alwaysstyle
              • Vl-jp-reportcard-aux
              • Vl-interface-alwaysstyle
              • Vl-design-alwaysstyle
              • Vl-jp-description-locations
              • Vl-jp-reportcard
              • Vl-pp-stringlist-lines
              • Vl-jp-design-locations
              • Vl-datatype-svbad-p
              • Unpacked-range-check
              • Sd-problem-major-p
              • Vl-alwaysstyle
            • Vl-server
            • Vl-gather
            • Vl-zip
            • Vl-main
            • Split-plusargs
            • Vl-shell
            • Vl-json
          • Mlib
          • Transforms
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Skip-detection

    Sd-patalist-compare

    Perform skip-detection for a single expression.

    Signature
    (sd-patalist-compare dom x y ctx) → probs
    Arguments
    dom — In practice, this is the strip-cars of x. That is, it is the list of all pattern names that were found in the expression, and which we need to investigate.
    x — The pattern produced for some particular expression.
        Guard (sd-patalist-p x).
    y — The global sd-patalist-p that we assume was produced for the entire module.
        Guard (sd-patalist-p y).
    ctx — Where this expression came from.
        Guard (vl-context1-p ctx).
    Returns
    probs — Type (sd-problemlist-p probs), given the guard.

    We recur over dom. For each pattern named in the expression, we use sd-keylist-find-skipped to try to find any skipped wires, collecting any problems that have been reported.

    Definitions and Theorems

    Function: sd-patalist-compare

    (defun sd-patalist-compare (dom x y ctx)
     (declare (xargs :guard (and (sd-patalist-p x)
                                 (sd-patalist-p y)
                                 (vl-context1-p ctx))))
     (let ((__function__ 'sd-patalist-compare))
      (declare (ignorable __function__))
      (if (atom dom)
          nil
        (let
           ((first (sd-keylist-find-skipped (cdr (hons-get (car dom) x))
                                            (cdr (hons-get (car dom) y))
                                            ctx))
            (rest (sd-patalist-compare (cdr dom)
                                       x y ctx)))
          (if first (cons first rest) rest)))))

    Theorem: sd-problemlist-p-of-sd-patalist-compare

    (defthm sd-problemlist-p-of-sd-patalist-compare
      (implies (and (force (sd-patalist-p x))
                    (force (sd-patalist-p y))
                    (force (vl-context1-p ctx)))
               (b* ((probs (sd-patalist-compare dom x y ctx)))
                 (sd-problemlist-p probs)))
      :rule-classes :rewrite)