R

Chapter 3

PicoBlaze Instruction Set

Table 3-1summarizes the entire PicoBlaze™ processor instruction set, which appears alphabetically. Instructions are listed using the KCPSM3 syntax. If different, the pBlazIDE syntax appears in parentheses. Each instruction includes an overview description, a functional description, and how the ZERO and CARRY flags are affected. For more details on each instruction, see Appendix C, “PicoBlaze Instruction Set and Event Reference.”

Table 3-1:PicoBlaze Instruction Set (alphabetical listing)

Instruction

Description

Function

ZERO

CARRY

 

 

 

 

 

ADD sX, kk

Add register sX with literal kk

sX Å sX + kk

?

?

 

 

 

 

 

ADD sX, sY

Add register sX with register sY

sX Å sX + sY

?

?

 

 

 

 

 

ADDCY sX, kk

Add register sX with literal kk with

sX Å sX + kk + CARRY

?

?

(ADDC)

CARRY bit

 

 

 

 

 

 

 

 

ADDCY sX, sY

Add register sX with register sY with

sX Å sX + sY + CARRY

?

?

(ADDC)

CARRY bit

 

 

 

 

 

 

 

 

AND sX, kk

Bitwise AND register sX with literal kk

sX Å sX AND kk

?

0

 

 

 

 

 

AND sX, sY

Bitwise AND register sX with register sY

sX Å sX AND sY

?

0

 

 

 

 

 

CALL aaa

Unconditionally call subroutine at aaa

TOS Å PC

-

-

 

 

PC Å aaa

 

 

 

 

 

 

 

CALL C, aaa

If CARRY flag set, call subroutine at aaa

If CARRY=1, {TOS Å PC,

-

-

 

 

PC Å aaa}

 

 

 

 

 

 

 

CALL NC, aaa

If CARRY flag not set, call subroutine at

If CARRY=0, {TOS Å PC,

-

-

 

aaa

PC Å aaa}

 

 

 

 

 

 

 

CALL NZ, aaa

If ZERO flag not set, call subroutine at aaa

If ZERO=0, {TOS Å PC,

-

-

 

 

PC Å aaa}

 

 

 

 

 

 

 

CALL Z, aaa

If ZERO flag set, call subroutine at aaa

If ZERO=1, {TOS Å PC,

-

-

 

 

PC Å aaa}

 

 

 

 

 

 

 

COMPARE sX, kk

Compare register sX with literal kk. Set

If sX=kk, ZERO Å 1

?

?

(COMP)

CARRY and ZERO flags as appropriate.

If sX<kk, CARRY Å 1

 

 

 

Registers are unaffected.

 

 

 

 

 

 

 

 

 

 

 

COMPARE sX, sY

Compare register sX with register sY. Set

If sX=sY, ZERO Å 1

?

?

(COMP)

CARRY and ZERO flags as appropriate.

If sX<sY, CARRY Å 1

 

 

 

Registers are unaffected.

 

 

 

 

 

 

 

 

 

 

 

DISABLE INTERRUPT

Disable interrupt input

INTERRUPT_ENABLE Å 0

-

-

(DINT)

 

 

 

 

 

 

 

 

 

PicoBlaze 8-bit Embedded Microcontroller

www.xilinx.com

19

UG129 (v1.1.2) June 24, 2008

Page 19
Image 19
Xilinx UG129 manual 1PicoBlaze Instruction Set alphabetical listing