yuzhicai
Junior Member level 3
I met two cases like following:
1.
always @ (a or b or c or d)
if (a && b)
out <= c;
else if (a)
out <= d;
else
out <= 1'b0;
2.
always @ (a or b or c or d)
if (a && b)
out <= c;
else if (a && ~b)
out <= d;
else
out <= 1'b0;
what is the difference between these two cases. Which is the better?
1.
always @ (a or b or c or d)
if (a && b)
out <= c;
else if (a)
out <= d;
else
out <= 1'b0;
2.
always @ (a or b or c or d)
if (a && b)
out <= c;
else if (a && ~b)
out <= d;
else
out <= 1'b0;
what is the difference between these two cases. Which is the better?