]>
Commit | Line | Data |
---|---|---|
3ad960bd JW |
1 | `ifdef EXECUTE |
2 | `INSN_ALU_A: begin | |
5c33c5c0 JW |
3 | `EXEC_NEWCYCLE |
4 | `EXEC_INC_PC | |
3ad960bd JW |
5 | end |
6 | `endif | |
7 | ||
8 | `ifdef WRITEBACK | |
9 | `INSN_ALU_A: begin | |
10 | case(opcode[5:3]) | |
11 | `INSN_alu_RLCA: begin | |
5c33c5c0 JW |
12 | `_A <= {`_A[6:0],`_A[7]}; |
13 | `_F <= {`_F[7:5],`_A[7],`_F[3:0]}; | |
3ad960bd JW |
14 | end |
15 | `INSN_alu_RRCA: begin | |
5c33c5c0 JW |
16 | `_A <= {`_A[0],`_A[7:1]}; |
17 | `_F <= {`_F[7:5],`_A[0],`_F[3:0]}; | |
3ad960bd JW |
18 | end |
19 | `INSN_alu_RLA: begin | |
5c33c5c0 JW |
20 | `_A <= {`_A[6:0],`_F[4]}; |
21 | `_F <= {`_F[7:5],`_A[7],`_F[3:0]}; | |
3ad960bd JW |
22 | end |
23 | `INSN_alu_RRA: begin | |
5c33c5c0 JW |
24 | `_A <= {`_A[4],`_A[7:1]}; |
25 | `_F <= {`_F[7:5],`_A[0],`_F[3:0]}; | |
3ad960bd JW |
26 | end |
27 | `INSN_alu_CPL: begin | |
5c33c5c0 JW |
28 | `_A <= ~`_A; |
29 | `_F <= {`_F[7],1'b1,1'b1,`_F[4:0]}; | |
3ad960bd JW |
30 | end |
31 | `INSN_alu_SCF: begin | |
5c33c5c0 | 32 | `_F <= {`_F[7:5],1'b1,`_F[3:0]}; |
3ad960bd JW |
33 | end |
34 | `INSN_alu_CCF: begin | |
5c33c5c0 | 35 | `_F <= {`_F[7:5],~`_F[4],`_F[3:0]}; |
3ad960bd JW |
36 | end |
37 | endcase | |
38 | end | |
39 | `endif |