SystemVerilog Data Types

Integers, Reals, and Simulation Behavior

The Hierarchy

Data types are categorized by their nature (Integral, Real, or Misc) and their simulation behavior (2-State vs. 4-State).

Integral Real Misc

2-State Types (Performance)

Simulate faster and take less memory (stores 0, 1). Ideal for testbenches and counters.

4-State Types (Modeling)

Accurately models hardware states (0, 1, X, Z). Used for RTL design and verifying resets.

Real & Misc Types

Summary of Built-in Types

Type Width States Signed?
bit User Defined 2-State Unsigned
logic / reg User Defined 4-State Unsigned
int 32-bit 2-State Signed
byte 8-bit 2-State Signed
integer 32-bit 4-State Signed