Differences between blocking and Non-blocking statements in
Verilog?

Answers were Sorted based on User's Feedback



Differences between blocking and Non-blocking statements in Verilog?..

Answer / amit malik

cp mistake in 1st one.
-----------------------------------

Blocking statements are executed on after another
represented by '='

Ex. lets take two variables
reg A:0;
reg B:1;
initial
begin
A = B;
B = A;
end

Ans
A = 1
B = 1

Non Blocking
instructions are executed concurrently
represented by '<='

Ex. lets take two variables
reg A:0;
reg B:1;
initial
begin
A <= B;
B <= A;
end

Ans
A = 1
B = 0

Is This Answer Correct ?    66 Yes 1 No

Differences between blocking and Non-blocking statements in Verilog?..

Answer / appu

@ Remya,

With non-blocking statements as shown above, A will always
get the OLD/previous value of B, and B will always get the
OLD/previous value of A.

Because, in a non-blocking statement assignment, the right
hand side of the statement gets evaluated right away, but
doesn't get assigned to the left hand side of the statement
until at the end of the time step.

Is This Answer Correct ?    20 Yes 1 No

Differences between blocking and Non-blocking statements in Verilog?..

Answer / amit malik

Blocking statements are executed on after another
represented by '='

Ex. lets take two variables
reg A:0;
reg B:1;
initial
begin
A = B;
B = A;
end

Ans
A = 1
B = 1

Non Blocking
instructions are executed concurrently
represented by '=>'

Ex. lets take two variables
reg A:0;
reg B:1;
initial
begin
A = B;
B = A;
end

Ans
A = 1
B = 0

Is This Answer Correct ?    35 Yes 18 No

Differences between blocking and Non-blocking statements in Verilog?..

Answer / darshan

DURING BLOCKING STATEMENTS, PREVIOUS VALUES GETS STORED TO
THE LHS.

WHERE AS IN NON BLOCKING STATEMENT, SINCE IT IS EXECUTING IN
PARALLEL 1ST SIMULATOR READS AND STORES IN TEMPORARY
REGISTER INTERNALLY IN SIMULATOR. THEN AT THE END OF THE
TIME UNIT IT IS ASSIGNED TO THE LHS.

ANYWAYS FROM MY POINT OF VIEW A OR B DONT GET THE PREV/OLD
VALUE

Is This Answer Correct ?    7 Yes 2 No

Differences between blocking and Non-blocking statements in Verilog?..

Answer / remya

Yes,the explanation is ok but after a particular time
units,the value of B must be equal to 1 no?

Is This Answer Correct ?    6 Yes 9 No

Post New Answer

More VLSI Interview Questions

Explain various adders and difference between them?

0 Answers   Intel,


Give the expression for CMOS switching power dissipation?

2 Answers   Infosys,


Approximately, what were the sizes of your transistors in the SRAM cell? How did you arrive at those sizes?

0 Answers   Infosys,


What r the phenomenon which come into play when the devices are scaled to the sub-micron lengths?

4 Answers   Intel,


What is charge sharing?

2 Answers   Cypress Semiconductor, Intel,






Insights of a pass gate. Explain the working?

0 Answers   Intel,


Process technology? What package was used and how did you model the package/system? What parasitic effects were considered?

0 Answers   Intel,


What is the critical path in a SRAM?

0 Answers  


Explain what is Verilog?

0 Answers  


Mention what are the two types of procedural blocks in Verilog?

0 Answers  


Describe a finite state machine that will detect three consecutive coin tosses (of one coin) that results in heads.

1 Answers   Intel,


what is the use of defpararm?

0 Answers  


Categories