• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
      • Theories
      • Rule-classes
      • Proof-builder
      • Recursion-and-induction
      • Hons-and-memoization
      • Events
      • Parallelism
      • History
      • Programming
        • Defun
        • Declare
        • System-utilities
        • Stobj
        • State
        • Mutual-recursion
        • Memoize
        • Mbe
        • Io
        • Defpkg
        • Apply$
        • Loop$
        • Programming-with-state
        • Arrays
        • Characters
        • Time$
        • Defmacro
        • Loop$-primer
        • Fast-alists
        • Defconst
        • Evaluation
        • Guard
        • Equality-variants
        • Compilation
        • Hons
        • ACL2-built-ins
        • Developers-guide
        • System-attachments
        • Advanced-features
        • Set-check-invariant-risk
        • Numbers
          • Df
          • Unsigned-byte-p
            • Defbyte
              • Defbytelist
              • Defbyte-standard-instances
              • Defbyte-ihs-theorems
                • Defbyte-ihs-theorems-implementation
              • Defbyte-implementation
            • Unsigned-byte-p-discussion
            • Unsigned-byte-listp
            • Bitops/signed-byte-p
            • Unsigned-byte-fix
            • Bytep
            • Nibblep
            • Ihs/unsigned-byte-p-lemmas
            • Unsigned-byte-p*
            • Unsigned-byte-p-basics
          • Posp
          • Natp
          • <
          • +
          • Bitp
          • Zero-test-idioms
          • Nat-listp
          • Integerp
          • *
          • -
          • Zp
          • Signed-byte-p
          • Logbitp
          • Sharp-f-reader
          • Expt
          • <=
          • Ash
          • Rationalp
          • =
          • Nfix
          • Logand
          • Floor
          • Random$
          • Integer-listp
          • Complex
          • Numbers-introduction
          • Truncate
          • Code-char
          • Char-code
          • Integer-length
          • Zip
          • Logior
          • Sharp-u-reader
          • Mod
          • Unary--
          • Boole$
          • /
          • Logxor
          • Ifix
          • Lognot
          • Integer-range-p
          • Allocate-fixnum-range
          • ACL2-numberp
          • Sharp-d-reader
          • Mod-expt
          • Ceiling
          • Round
          • Logeqv
          • Fix
          • Explode-nonnegative-integer
          • Max
          • Evenp
          • Zerop
          • Abs
          • Nonnegative-integer-quotient
          • Rfix
          • 1+
          • Pos-listp
          • Signum
          • Rem
          • Real/rationalp
          • Rational-listp
          • >=
          • >
          • Logcount
          • ACL2-number-listp
          • /=
          • Unary-/
          • Realfix
          • Complex/complex-rationalp
          • Logtest
          • Logandc1
          • Logorc1
          • Logandc2
          • Denominator
          • 1-
          • Numerator
          • Logorc2
          • The-number
          • Int=
          • Complex-rationalp
          • Min
          • Lognor
          • Zpf
          • Oddp
          • Minusp
          • Lognand
          • Imagpart
          • Conjugate
          • Realpart
          • Plusp
        • Efficiency
        • Irrelevant-formals
        • Introduction-to-programming-in-ACL2-for-those-who-know-lisp
        • Redefining-programs
        • Lists
        • Invariant-risk
        • Errors
        • Defabbrev
        • Conses
        • Alists
        • Set-register-invariant-risk
        • Strings
        • Program-wrapper
        • Get-internal-time
        • Basics
        • Packages
        • Oracle-eval
        • Defmacro-untouchable
        • <<
        • Primitive
        • Revert-world
        • Unmemoize
        • Set-duplicate-keys-action
        • Symbols
        • Def-list-constructor
        • Easy-simplify-term
        • Defiteration
        • Fake-oracle-eval
        • Defopen
        • Sleep
      • Operational-semantics
      • Real
      • Start-here
      • Debugging
      • Miscellaneous
      • Output-controls
      • Macros
      • Interfacing-tools
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
    • Math
    • Testing-utilities
  • Defbyte

Defbyte-ihs-theorems

Introduce some theorems about a defbyte instance and functions in the IHS library.

Introduction

Since unsigned-byte-p and signed-byte-p have certain formal relations with functions in IHS, similar relations can be proved for instances of defbyte.

This macro automates this process, by including the IHS basic definitions and by generating theorems. For now this macro generates just one theorem; more will be added in the future as needed.

The reason for not having defbyte itself generate these theorems is to avoid always including IHS when using defbyte. Having a separate macro leads to greater modularity.

General Form

(defbyte-ihs-theorems type)

Inputs

type

A symbol that names a fixtype previously introduced via defbyte. This specifies the defbyte instance for which the theorems are generated.

Generated Events

bytep-of-loghead-of-size

One of the following

  • If the defbyte instance is unsigned, a rewrite rule saying that (loghead size ...), where size is the byte size, satisfies the recognizer of the bytes.
  • If the defbyte instance is signed, a rewrite rule saying that (logext size ...), where size is the byte size, satisfies the recognizer of the bytes.

Subtopics

Defbyte-ihs-theorems-implementation
Implementation of defbyte-ihs-theorems.