
4.4 Instruction-set Grammar 77
opn mult_acc_prim()
{
action {
stage EX1..EX2:
G `EX2` = MR `EX2`; // one stage later than mult. operands
H `EX2` = macc(D `EX1`, E `EX1`, G `EX2`) rsrc(F `EX1`);
}
}
This example also shows that it is possible to annotate an extra (abstract) resource
to a statement in the action attribute, for example, to model a hardware conflict
on internal resources of a primitive operation. If the
macc operation would use
resource
F in both stage EX1 and stage EX2,this can be annotated as rsrc(F ‘EX1,EX2‘).
From this, the tools can then derive that a new
macc operation can only be started
every two cycles
Section 4.5.2 explains how to solve ...