PowerPC support of ?for and next.  In this check in I have comments which suggest that I'd like to support a command called 'i' for pushing the current for counter onto the data stack.  The core reason for this command is that the PowerPC code would be more efficient if it used the special purpose register CTR for the for counter, instead of the top of the return stack.  And, therefore, there would have to be a special command for getting the value of the loop counter.  On the i386 the word i would simply perform r@ as coded today.  However, on the PowerPC i would copy the value from the special purpose register CTR.  In order to preserve nested loops and in order to preserve stack effects, at the beginning of a for loop the current CTR value would be pushed onto the return stack.
PowerPC support of ?for and next.  In this check in I have comments
which suggest that I'd like to support a command called 'i' for
pushing the current for counter onto the data stack.  The core reason
for this command is that the PowerPC code would be more efficient if
it used the special purpose register CTR for the for counter, instead
of the top of the return stack.  And, therefore, there would have to
be a special command for getting the value of the loop counter.  On
the i386 the word i would simply perform r@ as coded today.  However,
on the PowerPC i would copy the value from the special purpose
register CTR.  In order to preserve nested loops and in order to
preserve stack effects, at the beginning of a for loop the current CTR
value would be pushed onto the return stack.

Also, if i is accepted, I also believe that the word j has usefulness
for getting the value of the outer loop.  Though nested loops are
computationally expensive, sometimes they are necessary.  On both the
i386 and the PowerPC j would fetch the second word on the return
stack.


git-svn-id: d30bc67f9752ee73d01a47c5a6f3e1bf6c1de4c7@186 f1bc7e2d-46f1-0310-96be-f91141564092

nickhen/muforth,nickhen/muforth