HDL & Verification
What is the advantage of using SystemVerilog's always_ff and always_comb instead of Verilog's always?
- Aalways_ff always doubles circuit speed
- Balways_comb makes simulation unnecessary
- CTools know the designer's intent (flip-flops or combinational logic) and can warn when the result differs, for example a latch
Show answer and explanation
Answer: C. Tools know the designer's intent (flip-flops or combinational logic) and can warn when the result differs, for example a latch
Verilog's always can describe flip-flops, combinational logic or latches, so tools do not know the designer's intent. Writing always_ff declares flip-flops and always_comb declares combinational logic, so tools can issue warnings or errors when, for example, an incomplete condition infers a latch. always_comb also derives its sensitivity automatically from the signals it reads.
- A. It has nothing to do with speed.
- B. Simulation is still needed.
- C. Correct. always_comb also determines its sensitivity list automatically.