ADSP-2126x SHARC Processor Hardware Reference
3-17
Program Sequencer
•
PC stack full.
Bit 21 (
PCFL
) indicates that the PC stack is full (if 1)
or not full (if 0)—not a sticky bit, cleared by a
POP
.
•
PC stack empty.
Bit 22 (
PCEM
) indicates that the PC stack is empty
(if 1) or not empty (if 0)—not sticky, cleared by a
PUSH
.
lists all the bits in the
STYKx
register.
To prevent a PC stack overflow, the PC stack full condition generates the
(maskable) stack overflow interrupt (
SOVFI
). This interrupt occurs when
the PC stack has 29 of 30 locations filled (the almost full state). The PC
stack full interrupt occurs when at this point because the PC stack full
interrupt service routine needs that last location for its return address.
The address of the top of the PC stack is available in the
PC
stack pointer
(
PCSTKP
) register. The value of
PCSTKP
is zero when the PC stack is empty,
is 1 through 30 when the stack contains data, and is 31 when the stack
overflows. A write to
PCSTKP
takes effect after a one cycle delay. If the PC
stack is overflowed, a write to
PCSTKP
has no effect. This register can be
read from and written to.
The overflow and full flags provide diagnostic aid only. Programs should
not use these flags for runtime recovery from overflow. Note that the sta-
tus stack, loop stack overflow, and PC stack full conditions trigger a
maskable interrupt.
The empty flags can ease stack saves to memory. Programs can monitor
the empty flag when saving a stack to memory to determine when the DSP
has transferred all values.
Conditional Sequencing
The sequencer supports conditional execution with conditional logic, as
illustrated in
. This logic evaluates conditions for
conditional (
IF
) instructions and loop (
DO/UNTIL
) terminations. The con-
ditions are based on information from the arithmetic status registers
Summary of Contents for ADSP-21261 SHARC
Page 30: ...Contents xxx ADSP 2126x SHARC Processor Hardware Reference ...
Page 40: ...Register Diagram Conventions xl ADSP 2126x SHARC Processor Hardware Reference ...
Page 58: ...Differences From Previous SHARCs 1 18 ADSP 2126x SHARC Processor Hardware Reference ...
Page 112: ...Secondary Processing Element PEy 2 54 ADSP 2126x SHARC Processor Hardware Reference ...
Page 178: ...Summary 3 66 ADSP 2126x SHARC Processor Hardware Reference ...
Page 204: ...DAG Instruction Summary 4 26 ADSP 2126x SHARC Processor Hardware Reference ...
Page 322: ...Setting Up DMA 7 32 ADSP 2126x SHARC Processor Hardware Reference ...
Page 436: ...SPORT Programming Examples 9 86 ADSP 2126x SHARC Processor Hardware Reference ...
Page 521: ...ADSP 2126x SHARC Processor Hardware Reference 11 31 Input Data Port rts IDP_ISR end ...
Page 522: ...Input Data Port Programming Example 11 32 ADSP 2126x SHARC Processor Hardware Reference ...
Page 590: ...Timer Programming Examples 14 20 ADSP 2126x SHARC Processor Hardware Reference ...
Page 796: ...I O Processor Registers A 174 ADSP 2126x SHARC Processor Hardware Reference ...
Page 800: ...B 4 ADSP 2126x SHARC Processor Core Manual ...
Page 846: ...Index I 36 ADSP 2126x SHARC Processor Hardware Reference ...