Non-blocking assignment
// this implements 3 parallel flip-flopsalways @(posedge clk) begin B = A; D = C; F = E; end
// this implements a shift registeralways @(posedge clk) begin B <= A; C <= B; D <= C; end
// this implements a shift registeralways @(posedge clk) begin {D, C, B} = {C, B, A}; end
Non-blocking assignment is also known as RTL assignment
- If used in an always block triggered by a clock edge
- Mimics register-transfer–level semantics: All flip-flops change together