HYUNDAI MicroElectronics
GMS82512/16/24
Branch / Jump Operation
OP
BYTE CYCLE
FLAG
NVGBHIZC
NO.
MNENONIC
OPERATION
CODE
NO.
NO
4/6
5/7
4/6
5/7
1
2
3
4
BBC A.bit,rel
BBC dp.bit,rel
BBS A.bit,rel
BBS dp.bit,rel
y2
2
Branch if bit clear :
- - - - - - - -
- - - - - - - -
y3
3
if(bit) = 0, then PC ꢀ PC + rel
x2
2
Branch if bit clear :
x3
3
if(bit) = 1, then PC ꢀ PC + rel
Branch if carry bit clear :
if(C) = 0, then PC ꢀ PC + rel
5
BCC rel
50
2
2/4
MM - - - - Z -
6
7
BCS rel
BEQ rel
BMI rel
BNE rel
BPL rel
BRA rel
BVC rel
D0
F0
90
70
10
2F
30
2
2
2
2
2
2
2
2/4
2/4
2/4
2/4
2/4
4
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
Branch if carry bit set : If (C) =1, then PC ꢀ PC + rel
Branch if equal : if (Z) = 1, then PC ꢀ PC + rel
Branch if munus : if (N) = 1, then PC ꢀ PC + rel
Branch if not equal : if (Z) = 0, then PC ꢀ PC + rel
Branch if not minus : if (N) = 0, then PC ꢀ PC + rel
Branch always : PC ꢀ PC + rel
8
9
10
11
12
2/4
Branch if overflow bit clear :
- - - - - - - -
- - - - - - - -
If (V) = 0, then PC ꢀ PC + rel
Branch if overflow bit set :
13
BVS rel
B0
2
2/4
If (V) = 1, then PC ꢀ PC + rel
Subroutine call
14
15
CALL !abs
CALL [dp]
3B
5F
3
2
8
8
M(SP)ꢀ(PCH), SPꢀSP-1, M(SP)ꢀ(PCL), SPꢀSP-1
- - - - - - - -
if !abs, PC ꢀ abs ; if [dp], PCL ꢀ (dp), PCH ꢀ (dp+1)
16
17
CBNE dp,rel
CBNE dp + X,
rel
FD
8D
3
3
5/7
6/8
Compare and branch if not equal ;
- - - - - - - -
- - - - - - - -
- - - - - - - -
If A ≠ (M), then PC ꢀ PC + rel.
18
19
20
21
22
23
DBNE dp,rel
AC
7B
1B
1F
3F
4F
3
2
3
3
2
2
5/7
4/6
3
Decrement and branch if not equal :
if (M) ≠ 0, then PC ꢀ PC + rel.
Unconditional jump
DBNE Y,rel
JMP !abs
JMP [!abs]
JMP [dp]
PCALL
5
PC ꢀ jump address
4
6
U-page call : M(SP) ꢀ (PCH), SP ꢀ SP -1,
M(SP) ꢀ (PCL), SP ꢀ SP -1,
PCL ꢀ (upage), PCH ꢀ "OFFH"
Table call :
- - - - - - - -
- - - - - - - -
24
TCALL n
nA
1
8
M(SP) ꢀ (PCH), SP ꢀ SP -1,
M(SP) ꢀ (PCL), SP ꢀ SP -1
PCL ꢀ (Table vector L), PCH ꢀ (Table vector H)
Control Operation & etc.
OP
CODE
BYTE CYCLE
FLAG
NVGBHIZC
NO.
MNENONIC
BRK
OPERATION
NO.
NO
1
0F
1
8
Software interrupt:
B ꢀ “1”, M(SP) ꢀ (PCH), SP ꢀ SP - 1,
M(s) ꢀ (PCL), SP ꢀ S - 1, M(SP) ꢀ PSW,
SP ꢀ SP - 1, PCL ꢀ (0FFDEH), PCH ꢀ (0FFDFH)
- - - 1 - 0 - -
2
3
4
DI
60
E0
FF
1
1
1
3
3
2
- - - - - 0 - -
- - - - - 1 - -
- - - - - - - -
Disable interrupts : I ꢀ “0”
Enable interrupts : I ꢀ “1”
No operation
EI
NOP
FEB. 2000 Ver 1.00
xviii