![](http://datasheet.mmic.net.cn/370000/TR4101_datasheet_16743144/TR4101_199.png)
FlexLink Interface
8-39
8.2.4 Operation and Functional Waveforms
A CU can implement single or multicycle instructions. These are
instructions that write results back to the CU registers or the TR4101
registers. This section describes a general mechanism for instruction
handling.
As soon as the CU decodes a valid instruction, it must assert ASELP to
prevent the TR4101 from signaling a reserved instruction exception. The
CU must continue to assert ASELP during stall cycles. It can then start
the operation by using the operands from CRSP[31:0] and CRTP[31:0].
The CU must make sure that CRX_VALIDN is driven LOW by the end of
the cycle. If CRX_VALIDN is HIGH, it means that the operands it has just
obtained are not valid, and it should obtain the operands again in the
next cycle and then restart the operation.
The TR4101 guarantees at least one X stage cycle where CRX_VALIDN
is LOW. If you want to save power, and performance is less of an issue,
the CU can check to see if CRX_VALIDN is LOW before loading the
operands from CRSP[31:0] and CRTP[31:0] to start the operation.
Depending on where the WB is, one of the following events will occur:
If the instruction is one that writes the result back to the TR4101’s
Register, the CU has to assert ASTALLP to stall the TR4101 until the
operation is complete. The CU deasserts ASTALLP in the same
cycle that it puts the result onto AXBUSP[31:0].
If, for any reason, the TR4101 is still stalling after ASTALLP is
deasserted, as indicated by an active HIGH CRUN_INN signal, the
CU can still keep ASTALLP deasserted, but has to make sure that a
valid result is on AXBUSP[31:0] in the last cycle before the TR4101
goes on to the next run cycle.
To achieve this, the CU can drive AXBUSP[31:0] the whole time the
TR4101 is stalling. This period, from when the CU decodes a valid
instruction until the CU finishes driving AXBUSP[31:0], is considered
to be an extended X stage of the instruction. If CKILLXP is asserted
during this extended X stage, the CU should kill the instruction, and
the TR4101 will then make sure that no WB happens at the end of
the cycle.