Jeremy Siek 4 tahun lalu
induk
melakukan
2e6c10b98f
1 mengubah file dengan 7 tambahan dan 7 penghapusan
  1. 7 7
      book.tex

+ 7 - 7
book.tex

@@ -9008,13 +9008,13 @@ same way as the \ALLOC{\itm{len}}{\itm{type}} form
 (Section~\ref{sec:select-instructions-gc}). The only difference is
 that you should place the \itm{arity} in the tag that is stored at
 position $0$ of the vector. Recall that in
-Section~\ref{sec:select-instructions-gc} we used the first $56$ bits
-of the 64-bit tag, but that the rest were unused. So the arity goes
-into the tag in bit positions $57$ through $63$.
+Section~\ref{sec:select-instructions-gc} a portion of the 64-bit tag
+was not used. We store the arity in the $5$ bits starting at position
+$58$.
 
 Compile the \code{procedure-arity} operator into a sequence of
 instructions that access the tag from position $0$ of the vector and
-shift it by $57$ bits to the right.
+extract the $5$-bits starting at position $58$ from the tag.
 
 \begin{figure}[p]
 \begin{tikzpicture}[baseline=(current  bounding  box.center)]
@@ -12173,8 +12173,8 @@ lowering the primitive operations into x86 instructions.  So we need
 to translate the new \code{PVector} operations to x86.  To do so, the
 first question we need to answer is how will we differentiate the two
 kinds of values (vectors and proxies) that can inhabit \code{PVector}.
-We need just one bit to accomplish this, so we use the $57$th bit of
-the 64-bit tag at the front of every vector (see
+We need just one bit to accomplish this, and use the bit in position
+$57$ of the 64-bit tag at the front of every vector (see
 Figure~\ref{fig:tuple-rep}). So far, this bit has been set to $0$, so
 for \code{inject-vector} we leave it that way.
 \begin{lstlisting}
@@ -12182,7 +12182,7 @@ for \code{inject-vector} we leave it that way.
 |$\Rightarrow$|  
 movq |$e'_1$|, |$\itm{lhs'}$|
 \end{lstlisting}
-On the other hand, \code{inject-proxy} sets the $57$th bit to $1$.
+On the other hand, \code{inject-proxy} sets bit $57$ to $1$.
 \begin{lstlisting}
 (Assign |$\itm{lhs}$| (Prim 'inject-proxy (list |$e_1$|)))
 |$\Rightarrow$|