mirror of
https://github.com/openhwgroup/cva5.git
synced 2025-04-20 12:07:53 -04:00
fixed quick div reuse timing bug
This commit is contained in:
parent
5f2dfd21db
commit
c9015dc180
3 changed files with 5 additions and 5 deletions
|
@ -112,7 +112,7 @@ module div_quick_clz
|
|||
always_ff @ (posedge clk) begin
|
||||
if (firstCycle)
|
||||
Q <= B_is_zero ? '1 : '0;
|
||||
else if (~terminate)
|
||||
else if (~terminate & running)
|
||||
Q <= new_Q_bit;
|
||||
end
|
||||
|
||||
|
@ -122,7 +122,7 @@ module div_quick_clz
|
|||
always @ (posedge clk) begin
|
||||
if (firstCycle)
|
||||
R <= A_r;
|
||||
else if (~terminate)
|
||||
else if (~terminate & running)
|
||||
R <= new_R;
|
||||
end
|
||||
|
||||
|
|
|
@ -136,7 +136,7 @@ module div_quick_clz_mk2
|
|||
always_ff @ (posedge clk) begin
|
||||
if (firstCycle)
|
||||
Q <= B_is_zero ? '1 : '0;
|
||||
else if (~terminate)
|
||||
else if (~terminate & running)
|
||||
Q <= Q | new_Q_bit;
|
||||
end
|
||||
|
||||
|
@ -146,7 +146,7 @@ module div_quick_clz_mk2
|
|||
always @ (posedge clk) begin
|
||||
if (firstCycle)
|
||||
R <= A_r;
|
||||
else if (~terminate)
|
||||
else if (~terminate & running)
|
||||
R <= new_R;
|
||||
end
|
||||
|
||||
|
|
|
@ -110,7 +110,7 @@ module div_quick_naive
|
|||
Q <= B_is_zero ? '1 : 0;
|
||||
R <= A;
|
||||
end
|
||||
else if (~terminate) begin
|
||||
else if (~terminate & running) begin
|
||||
Q <= new_Q_bit;
|
||||
R <= new_R;
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue