![Intel NIOS II Owner Reference Manual Download Page 102](http://html1.mh-extra.com/html/intel/nios-ii/nios-ii_owner-reference-manual_2071826102.webp)
Table 50.
Move Instructions
Instruction
Description
mov
movhi
movi
movui
movia
mov
copies the value of one register to another register.
movi
moves a 16-bit signed immediate value to a
register, and sign-extends the value to 32 bits.
movui
and
movhi
move a 16-bit immediate value into the lower
or upper 16-bits of a register, inserting zeros in the remaining bit positions. Use
movia
to load a register with an
address.
3.9.4. Comparison Instructions
The Nios II architecture supports a number of comparison instructions. All of these
compare two registers or a register and an immediate value, and write either one (if
true) or zero to the result register. These instructions perform all the equality and
relational operators of the C programming language.
Table 51.
Comparison Instructions
Instruction
Description
cmpeq
==
cmpne
!=
cmpge
signed >=
cmpgeu
unsigned >=
cmpgt
signed >
cmpgtu
unsigned >
cmple
unsigned <=
cmpleu
unsigned <=
cmplt
signed <
cmpltu
unsigned <
cmpeqi
cmpnei
cmpgei
cmpgeui
cmpgti
cmpgtui
cmplei
cmpleui
cmplti
cmpltui
These instructions are immediate versions of the comparison operations. They compare the value of a
register and a 16-bit immediate value. Signed operations sign-extend the immediate value to 32-bits.
Unsigned operations fill the upper bits with zero.
3.9.5. Shift and Rotate Instructions
The following instructions provide shift and rotate operations. The number of bits to
rotate or shift can be specified in a register or an immediate value.
3. Programming Model
NII-PRG | 2018.04.18
Nios II Processor Reference Guide
102