Register Model
e200z3 Power Architecture Core Reference Manual, Rev. 2
2-12
Freescale Semiconductor
2.6
Registers for Branch Operations
This section describes registers used by Book E branch and CR operations.
2.6.1
Condition Register (CR)
CR, shown in
, reflects the result of certain operations and provides a mechanism for testing and
branching.
CR bits are grouped into eight 4-bit fields, CR0–CR7, which are set as follows:
•
Specified CR fields are set by a move to the CR from a GPR (mtcrf).
•
A specified CR field is set by a move to the CR from another CR field (mcrf), or from the XER
(mcrxr).
•
CR0 may be set as the implicit result of an integer instruction.
•
A specified CR field may be set as the result of either an integer or a floating-point compare
instruction (including SPE and SPFP compare instructions).
Instructions are provided to perform logical operations on individual CR bits and to test individual CR bits.
Table 2-5. XER Field Descriptions
Bits
Name
Description
32
SO
Summary overflow. Set when an instruction (except
mtspr
) sets the overflow bit (OV). SO remains set until it
is cleared by
mtspr[XER]
or
mcrxr
. SO is not altered by compare instructions or other instructions that cannot
overflow (except
mtspr[XER]
and
mcrxr
). Executing
mtspr[XER]
with the values 0 for SO and 1 for OV clears
SO and sets OV.
33
OV
Overflow. X-form add, subtract from, and negate instructions with OE=1 set OV if the carry out of bit 32 is not
equal to the carry out of bit 33. Otherwise, they clear OV to indicate a signed overflow. X-form multiply low word
and divide word instructions with OE=1 set OV if the result cannot be represented in 32 bits (
mullwo
,
divwo
,
and
divwuo
) and clear OV otherwise. OV is not altered by compare instructions or other instructions that
cannot overflow (except
mtspr[XER]
and
mcrxr
).
34
CA
Carry. Add carrying, subtract from carrying, add extended, and subtract from extended instructions set CA if
there is a carry out of bit 32 and clear it otherwise. CA can be used to indicate unsigned overflow for add and
subtract operations that set CA. Shift right algebraic word instructions set CA if any 1 bits are shifted out of a
negative operand and clear CA otherwise. Compare instructions and instructions that cannot carry (except
Shift Right Algebraic Word,
mtspr[XER]
, and
mcrxr
) do not affect CA.
35–56
—
Reserved, should be cleared.
57–63 Number
of bytes
Supports emulation of load and store string instructions. Specifies the number of bytes to be transferred by a
load string indexed or store string indexed instruction.
32
35 36
39 40
43 44
47 48
51 52
55 56
59 60
63
Field
CR0
CR1
CR2
CR3
CR4
CR5
CR6
CR7
Reset
Undefined on
m_por assertion, unchanged on p_reset_b
assertion
R/W
R/W
Figure 2-7. Condition Register (CR)
Содержание e200z3
Страница 1: ...e200z3 Power Architecture Core Reference Manual Supports e200z3 e200z335 e200z3coreRM Rev 2 06 2008 ...
Страница 32: ...e200z3 Power Architecture Core Reference Manual Rev 2 xii Freescale Semiconductor ...
Страница 50: ...Register Model e200z3 Power Architecture Core Reference Manual Rev 2 2 2 Freescale Semiconductor ...
Страница 238: ...Memory Management Unit e200z3 Power Architecture Core Reference Manual Rev 2 5 16 Freescale Semiconductor ...
Страница 332: ...Power Management e200z3 Power Architecture Core Reference Manual Rev 2 8 4 Freescale Semiconductor ...
Страница 424: ...Revision History e200z3 Power Architecture Core Reference Manual Rev 2 A 2 Freescale Semiconductor ...