hp-saturn/opcodes/Cx.v
Raphael Jacquot cbfbe4eb3f renumber debug opcodes
add add_cst and sub_cst alu opcodes
port pointer math to use ALU
make A[ab]x more readable
2019-02-11 15:36:51 +01:00

28 lines
548 B
Verilog

/******************************************************************************
* Cx
* maths...
*
*/
`include "decstates.v"
`DEC_CX: begin
case (nb_in)
4'hA: begin
if (!hex_dec) begin
{Carry, A[19:0]} = A[19:0] + C[19:0];
decstate <= `DEC_START;
end
`ifdef SIM
$display("%5h A=A+C\tA%s", inst_start_PC, hex_dec?"\t\t\t <=== DEC MODE NOT IMPLEMENTED":"");
`endif
end
default: begin
$display("ERROR : DEC_CX");
decode_error <= 1;
end
endcase
end