Samsung S3C84I8 User Manual page 177

Table of Contents

Advertisement

S3C84I8/F84I8/C84I9/F84I9
ENTER
— Enter
ENTER
SP ← SP – 2
Operation:
@SP ← IP
IP ← PC
PC ← @IP
IP ← IP + 2
This instruction is useful when implementing threaded-code languages. The contents of the
instruction pointer are pushed to the stack. The program counter (PC) value is then written to the
instruction pointer. The program memory word that is pointed to by the instruction pointer is
loaded into the PC, and the instruction pointer is incremented by two.
No flags are affected.
Flags:
Format:
opc
The diagram below shows an example of how to use an ENTER statement.
Example:
Address
Data
IP
0050
PC
0040
0022
22
Data
Stack
Before
Address
40
Enter
41
Address H
42
Address L
43
Address H
Memory
Bytes
1
Address
IP
0043
Data
PC
0110
1F
01
10
0020
20
IPH
21
IPL
22
Data
Stack
INSTRUCTION SET
Cycles
Opcode
(Hex)
14
1F
After
Data
Address
40
Enter
41
Address H
42
Address L
43
Address H
110
Routine
00
50
Memory
Data
1F
01
10
6-41

Advertisement

Table of Contents
loading

This manual is also suitable for:

S3c84i9S3f84i8S3f84i9

Table of Contents