Arithmetic Logic Unit; Unimplemented Instructions; Custom Instructions - Intel NIOS II Owner Reference Manual

Table of Contents

Advertisement

2. Processor Architecture
NII-PRG | 2018.04.18
For details about the
Reference chapter of the Nios II Processor Reference Handbook.
Related Information
Programming Model
Instruction Set Reference

2.3. Arithmetic Logic Unit

The Nios II ALU operates on data stored in general-purpose registers. ALU operations
take one or two inputs from registers, and store a result back in a register. The ALU
supports the data operations described in the table below. To implement any other
operation, software computes the result by performing a combination of the
fundamental operations.
Table 1.
Operations Supported by the Nios II ALU
Category
Arithmetic
The ALU supports addition, subtraction, multiplication, and division on signed and unsigned operands.
Relational
The ALU supports the equal, not-equal, greater-than-or-equal, and less-than relational operations (==, !=
>=, <) on signed and unsigned operands.
Logical
The ALU supports AND, OR, NOR, and XOR logical operations.
Shift and Rotate
The ALU supports shift and rotate operations, and can shift/rotate data by 0 to 31 bit positions per
instruction. The ALU supports arithmetic shift right and logical shift right/left. The ALU supports rotate left/
right.

2.3.1. Unimplemented Instructions

Some Nios II processor core implementations do not provide hardware to support the
entire Nios II instruction set. In such a core, instructions without hardware support
are known as unimplemented instructions.
The processor generates an exception whenever it issues an unimplemented
instruction so your exception handler can call a routine that emulates the operation in
software. Unimplemented instructions do not affect the programmer's view of the
processor.
For a list of potential unimplemented instructions, refer to the Programming Model
chapter of the Nios II Processor Reference Handbook.
Related Information
Programming Model

2.3.2. Custom Instructions

The Nios II architecture supports user-defined custom instructions. The Nios II ALU
connects directly to custom instruction logic, enabling you to implement operations in
hardware that are accessed and used exactly like native instructions.
Refer to "Custom Instruction Tab" in the Instantiating the Nios II Processor chapter of
the Nios II Processor Reference Handbook for additional information.
and
instructions, refer to the Instruction Set
rdprs
wrprs
on page 36
on page 169
on page 36
Details
Nios II Processor Reference Guide
17

Advertisement

Table of Contents
loading

Table of Contents