Datasheet

2-10 MCF5407 User’s Manual
Programming Model
2.2.1.6 MAC Programming Model
Figure 2-3 shows the registers in the MAC portion of the user programming model. These
registers are described as follows:
Accumulator (ACC)—This 32-bit, read/write, general-purpose register is used to
accumulate the results of MAC operations.
Mask register (MASK)—This 16-bit general-purpose register provides an optional
address mask for MAC instructions that fetch operands from memory. It is useful in
the implementation of circular queues in operand memory.
MAC status register (MACSR)—This 8-bit register denes conguration of the
MAC unit and contains indicator ags affected by MAC instructions. Unless noted
otherwise, MACSR indicator ag settings are based on the nal result, that is, the
result of the nal operation involving the product and accumulator.
2.2.2 Supervisor Programming Model
The MCF5407 supervisor programming model is shown in Figure 2-3. Typically, system
programmers use the supervisor programming model to implement operating system
functions and provide memory and I/O control. The supervisor programming model
provides access to the user registers and additional supervisor registers, which include the
upper byte of the status register (SR), the vector base register (VBR), and registers for
conguring attributes of the address space connected to the Version 4 processor core. Most
supervisor-level registers are accessed by using the MOVEC instruction with the control
register denitions in Table 2-2.
Table 2-1. CCR Field Descriptions
Bits Name Description
7–5 Reserved, should be cleared.
4 X Extend condition code bit. Assigned the value of the carry bit for arithmetic operations; otherwise not
affected or set to a specified result. Also used as an input operand for multiple-precision arithmetic.
3 N Negative condition code bit. Set if the msb of the result is set; otherwise cleared.
2 Z Zero condition code bit. Set if the result equals zero; otherwise cleared.
1 V Overflow condition code bit. Set if an arithmetic overflow occurs, implying that the result cannot be
represented in the operand size; otherwise cleared.
0 C Carry condition code bit. Set if a carry-out of the data operand msb occurs for an addition or if a
borrow occurs in a subtraction; otherwise cleared.