We know that the difference between blocking statements and non-blocking statements is: blocking statements executes sequentially (execution of next statement is blocked until present one completes) and are used to perform in combinational circuits.
Example:
always@(*) begin
c = A & B;
D = C/A;
end
Here all the statements executes sequentially (blocking statement)
Whereas non-blocking statements execute parallelly (execution of next statement is not blocked) and are used to perform in sequential circuits.
Example: Take an example of shift register
always@posedge(clk) begin
A<=B;
B<=C;
C<=D;
end
Here all the statements executes parallely because it is non-blocking and we have used posedge clk
Now if you see the difference between begin end
and fork join
, the difference is: in begin end
, statements are executed in the order they are listed (i.e. sequentially), whereas in fork join
, statements are executed parallelly.
My question here is, in the above example of non-blocking statement, we have used begin end
but the statements are been executed parallelly not sequentially, but if you see in the difference between begin end
and fork join
it says begin end
executes the statements one after another.
Could someone explain with a clear answer to this?