Home / Learn Verilog / Hierarchical References: Peeking Inside
Hierarchical References: Peeking Inside
Testbenches can read internal signals with dots.
The gistTestbenches can read internal signals with dots.
The idea, explained simply
The basic idea
Write u1.count to read signal count inside instance u1.
Why this comes up
Handy for debugging; not synthesizable.
The mechanics
Use in testbenches only, never in RTL.
Where it is used
- Everyday RTL design
- FPGA and ASIC projects
- Testbenches and debugging
Try it
Reading u1.count from tbVerilog: edit and run
u1.q reaches inside the instance.
Quick check
1. Hierarchical references are for...
Not synthesizable.