TC1796
System Units (Vol. 1 of 2)
Peripheral Control Processor (PCP)
User’s Manual
11-89
V2.0, 2007-07
PCP, V2.0
11.11.16 EXIT, Exit Instruction
This section describes the EXIT instruction of the PCP.
EXIT
Syntax
EXIT EC, ST, INT, EP, cc_B
Description
Unconditionally exit channel program execution. Optionally
decrement counter CNT1 (EC = 1), disable further channel
invocation (ST = 1), generate an interrupt request (INT = 1)
if condition CONDCB is true. Field EP is used to set the
channel code entry point in Channel Resume Mode to either
the address of the next instruction (EP = 1) or to the start
address of the channel (EP = 0). The EXIT instruction is
finished with a context save operation.
The EP option is only in effect when Channel Resume
operation is globally selected through
PCP_CS.RCB = 0. If PCP_CS.RCB = 1, Channel
restart mode is selected for all channels, and the EP
field of the EXIT instruction is disregarded.
Operation
if (EC = 1) then CNT1 = CNT1 - 1
if (ST = 1) then R7_CEN = 0
if ((INT = 1) AND (cc_B = True)) then
activate_interrupt_request
if (EP = 1) then R7_PC = NextPC else R7_PC =
channel_entry_point
save_context
Flags
CN1Z