"gcd", test(list(op("="), reg("b"), constant(0))), branch(label("gcd_done")), assign("t", list(op("rem"), reg("a"), reg("b"))), assign("a", reg("b")), assign("b", reg("t")), go_to(label("gcd")), "gcd_done", go_to(reg("continue")), $\vdots$ // Before calling $\texttt{gcd}$, we assign to $\texttt{continue}$ // the label to which $\texttt{gcd}$ should return. assign("continue", label("after_gcd_1"))), go_to(label("gcd")), "after_gcd_1", $\vdots$ // Here is the second call to $\texttt{gcd}$, with a different continuation. assign("continue", label("after_gcd_2")), go_to(label("gcd")), "after_gcd_2"
Figure 5.12 Assigning labels to the continue register simplifies and generalizes the strategy shown in figure 5.11.
5.1.3   Subroutines