Skip to main content
  1. Tutorials/
  2. Verilog/

Verilog Design Methodologies & Modeling Styles

·473 words·3 mins· loading · loading · ·
Hardware Design Verilog Design Methodology RTL Modeling Hardware Design Digital Design Flow
Hardware Design
Axolot Logic
Author
Axolot Logic
Digital Design Engineer
Table of Contents
Verilog HDL Series - This article is part of a series.
Part 2: This Article

🎨 Verilog Design Methodologies
#

1. Bottom-Up Design
#

How it works: Start from basic building blocks like gates or small modules, and integrate them step by step into larger systems. Advantages:

  • Each component can be tested independently
  • Ideal for small or modular projects Example: Design a full-adder first, then build an 8-bit ripple-carry adder from multiple full-adders.

2. Top-Down Design
#

How it works: Begin with a high-level specification or block diagram, then divide it into submodules. Advantages:

  • Enables early architectural validation
  • More manageable in large projects Example: Design a CPU starting from the instruction set, then define submodules like ALU and register file.

3. Mixed Design (Hybrid Approach)
#

Real-World Usage: Most common in industry. How it’s done:

  • Top-level architecture is defined using top-down planning
  • Critical submodules (e.g., PLLs, memory controllers) are developed bottom-up.
graph TD
  A[Top-Level Spec] --> B[Submodule 1]
  A --> C[Submodule 2]
  B --> D[Gate-Level Implementation]
  C --> E[Third-Party IP]

📝 Verilog Modeling Styles
#

1. Behavioral Modeling
#

  • Use case: Algorithmic descriptions and control logic

  • Key constructs:

    • always @(*) for combinational logic
    • always @(posedge clk) for sequential logic Example:
module max_selector (
    input  [7:0] a,
    input  [7:0] b,
    output [7:0] y
);

    reg [7:0] y_reg;
    assign y = y_reg;

    always @(*) begin
        y_reg = (a > b) ? a : b;
    end

endmodule

2. Dataflow Modeling
#

  • Typical for: Arithmetic units, multiplexers, buses

  • Important points:

    • assign statements are evaluated continuously
    • The left-hand side must be a wire Example:
module mux2to1 (
    input        sel,
    input  [7:0] in1,
    input  [7:0] in2,
    output [7:0] out
);

    assign out = (sel) ? in1 : in2;

endmodule

3. Structural Modeling
#

  • Real-world analogy: Like wiring components in a schematic

  • Critical notes:

    • Uses module instantiations
    • Port mapping can be by name or position Example:
module and_gate (
    input  a,
    input  b,
    output y
);

    assign y = a & b;

endmodule

module top_module (
    input  in1,
    input  in2,
    output out
);

    and_gate U1 (
        .a(in1),
        .b(in2),
        .y(out)
    );

endmodule

4. Gate-Level Modeling
#

  • Modern use: Mostly handled automatically by synthesis tools

  • When used:

    • ASIC standard cell mapping
    • FPGA primitives (e.g., LUTs, DSPs) Example:
module and_gate_delayed (
    input  in1,
    input  in2,
    output out
);

    and #(2) G1 (out, in1, in2); // 2ns delayed AND gate

endmodule

🚀 Design Flow: From Code to Hardware
#

flowchart TD
  A[System Specification] --> B[Behavioral RTL Design]
  B --> C[RTL Simulation & Functional Verification]
  C --> D[Synthesis]
  D --> E[Gate-Level Netlist]
  E --> F[Place & Route]
  F --> G[Bitstream / GDSII Generation]
  G --> H[Timing / Power / DRC / LVS Verification]
  H -->|If Failed| B

This flow represents the typical lifecycle of a Verilog design — starting from behavioral RTL modeling, simulating it, then synthesizing it into gates, placing and routing it physically, and finally generating either a bitstream for FPGA programming or mask data for ASIC fabrication.


Verilog HDL Series - This article is part of a series.
Part 2: This Article

Related

Introduction to Verilog: Basics for Digital Design
·753 words·4 mins· loading · loading
Hardware Design Verilog FPGA ASIC RTL Design Hardware Description Language
Hardware Design
Hardware Design Abstraction Levels in Verilog
·238 words·2 mins· loading · loading
Hardware Design Hardware Abstraction RTL Design Gate Level Transistor Level Digital Design
Hardware Design
Verilog Assignments: Procedural vs. Continuous Explained
· loading · loading
Hardware Design Verilog Assignments Continuous Assignment Procedural Assignment RTL Design Hardware Description Language
Hardware Design
Verilog Blocking vs. Non-Blocking Assignments
· loading · loading
Hardware Design Verilog Assignments Blocking Assignment NonBlocking Assignment RTL Design Sequential Logic
Hardware Design
Verilog Command-Line Input: $plusargs for Testbench Control
· loading · loading
Hardware Design Verilog Command Line Plusargs Testbench Simulation Control Hardware Verification
Hardware Design
Verilog Compiler Directives & Macros: Conditional Compilation & Code Reuse
· loading · loading
Hardware Design Verilog Directives Verilog Macros Conditional Compilation Code Reuse Hardware Description Language
Hardware Design