Added register indirect unconditional jump

This commit is contained in:
(Tim) Efthimis Kritikos 2023-02-24 13:04:32 +00:00
parent 9ed3dc3312
commit 3e484a0ceb

View File

@ -514,6 +514,27 @@ always @( CIR or SIMPLE_MICRO or seq_addr_input ) begin
reg_write_addr={1'b1,CIR[10:8]};
seq_addr_entry=`UCODE_POP_ENTRY;
end
11'b1111_1111_100:begin
/* JMP - Unconditional indirect within segment jump */
/* 1 1 1 1 1 1 1 1 | MOD 1 0 1 R/M | < DISP-LO > | < DISP-HI > */
`start_aligning_instruction
opcode_size=1;
has_operands=0;
Wbit=1;
IN_MOD={1'b0,CIR[7:6]};
RM=CIR[2:0];
in_alu1_sel1=2'b11;
if (IN_MOD==2'b11)begin
in_alu1_sel2=2'b01;
reg_read_port2_addr={Wbit,RM};
next_state=`PROC_EX_STATE_ENTRY;
end else begin
in_alu1_sel2=2'b00;
next_state=`PROC_MEMIO_READ;
end
ALU_1OP=`ALU_OP_ADD;
OUT_MOD=3'b101;
end
default:begin
`invalid_instruction
end