Archived
1
0

minor fixes on alu

This commit is contained in:
Erick
2022-03-08 13:53:49 +01:00
parent 5cac1f0b68
commit 062c1aefb3
3 changed files with 9 additions and 7 deletions
+1
View File
@@ -47,6 +47,7 @@ always @(*) begin
alu_out = tmpOut;
end
//TODO: improve this part using increment/decrement logic
if (alu_out < 0)
flag = 0; // negative flag
else if (alu_out = 0)
+7 -7
View File
@@ -4,14 +4,14 @@ package lookahead (
input [15:0]b,
);
res = and16(y, a, b);
res = and16(y, a, b);
for (i=0; i<15 ; i=i+1)
if (res[i] = 0)
carry_bit[i] = 0;
else
carry_bit[i] = 1;
end
for (i=0; i<15 ; i=i+1)
if (res[i] = 0)
carry_bit[i] = 0;
else
carry_bit[i] = 1;
end
end
endpackage
+1
View File
@@ -0,0 +1 @@
import alu::*;