Samsung S3F80JB manual Next Next, Operation PC ← @ IP

Models: S3F80JB

1 346
Download 346 pages 34.13 Kb
Page 188
Image 188

INSTRUCTION SET

S3F80JB

 

 

NEXT — Next

NEXT

Operation: PC @ IP

IP IP + 2

The NEXT instruction is useful when implementing threaded-code languages. The program memory word that is pointed to by the instruction pointer is loaded into the program counter. The instruction pointer is then incremented by two.

Flags: No flags are affected.

Format:

Bytes Cycles Opcode (Hex)

opc

1 10 0F

Example: The following diagram shows one example of how to use the NEXT instruction.

Address

IP

PC

0043

0120

Before

Data

AddressData

43 Address H 01

44 Address L 10

45 Address H

120 Next

Memory

Address

IP 0045

PC 0130

After

Data

Address

43

44

45

130

Data

Address H

Address L

Address H

Routine

Memory

6-60

Page 188
Image 188
Samsung S3F80JB manual Next Next, Operation PC ← @ IP