Commit f614b9e5 authored by Iulian Gheorghiu's avatar Iulian Gheorghiu

Fix ANDI, CBR, ORI, SBR instruction not setup the flags.

parent 0cb37837
......@@ -830,7 +830,9 @@ begin
ALU_FLAG_Z_OUT <= &(~out[15:0]);
end
end
if(SEL_INSTRUCTION_AND |
if(SEL_INSTRUCTION_ANDI_CBR |
SEL_INSTRUCTION_ORI_SBR |
SEL_INSTRUCTION_AND |
SEL_INSTRUCTION_OR |
SEL_INSTRUCTION_COM |
SEL_INSTRUCTION_EOR)
......@@ -1010,7 +1012,7 @@ module mega_core # (
output reg [(VECTOR_INT_TABLE_SIZE == 0 ? 0 : VECTOR_INT_TABLE_SIZE - 1):0]int_rst,
output reg wdt_rst_out
);
reg [7:0]ALU_FLAGS = 0; //Carry Flag
wire ALU_FLAG_C_OUT; //Carry Flag
wire ALU_FLAG_Z_OUT; //Zero Flag
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment