Reciprocal Table Lookup - Nintendo Ultra64 Programmer's Manual

Rsp
Table of Contents

Advertisement

Type
vt[element]
low
vrcpl,
vrsql
Revision 1.0
vd[vs]
low
lookup source and previous, write result

Reciprocal Table Lookup

The results are computed by a table lookup using 10 bits of precision. The
input is shifted up to remove leading 0's (or 1's) (actually, the first
non-leading digit is also removed, since we know what it is) and the next 10
bits are used to index into the reciprocal table. The 16 bits in the table at this
index are used to construct the result, which is obtained by shifting down an
appropriate number of bits and possibly complementing (for negative
input).
For rcp, the radix point of the output is shifted right compared to the input.
For example, for double precision rcp, with input format S15.16, the
output result will be S16.15, requiring the result to be multiplied by 2 in
order to maintain the same format.
For rsq, the radix point moves to the left by one-half the number of integer
bits. Think of it this way:
input
a
=
and:
1
table
------------------ -
=
a
k
2
k
2
VU Divide Instructions
77

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents