summaryrefslogtreecommitdiff
path: root/thesis/code-addresses.tex
diff options
context:
space:
mode:
authorCamil Staps2017-01-02 21:52:39 +0100
committerCamil Staps2017-01-02 21:52:39 +0100
commit5b2c98a29aac6d1e45b3f54b51e30c5acf695976 (patch)
tree7c074635e4b1fefecf43005010444dcb5d4d5ca0 /thesis/code-addresses.tex
parentExpand on note about tail recursion (diff)
Commentaar Mart
Diffstat (limited to 'thesis/code-addresses.tex')
-rw-r--r--thesis/code-addresses.tex5
1 files changed, 3 insertions, 2 deletions
diff --git a/thesis/code-addresses.tex b/thesis/code-addresses.tex
index 4dc7338..29d6257 100644
--- a/thesis/code-addresses.tex
+++ b/thesis/code-addresses.tex
@@ -20,7 +20,8 @@ When the LSB is set, it switches to Thumb mode~\parencite[A2.3.2]{armv7ar}.
The fact that in ARM mode the two lowest bits of a value written to the PC are cleared automatically has been exploited in the ARM code generator:
these two bits are used to store information.
Bit 1 is used to mark a node as having reached head normal form%
- \footnote{A node is in \emph{head} or \emph{root normal form} when it cannot be rewritten itself (though its children may).}.
+ \footnote{A node is in \emph{head} or \emph{root normal form} when it cannot be rewritten itself (though its children may).}
+ (HNF).
Bit 0 is used in Clean's default garbage collector, the copying collector, to record whether a node has been copied to the other semispace already:
when cleared (the normal state of an address as stored on the heap), it has not been copied yet.
@@ -49,7 +50,7 @@ Flipping the meaning of the LSB in the garbage collector amounts to swapping \ua
By word-aligning all node entry addresses we lose one alignment byte per node entry address on average
(assuming that half of the node entry points are word-aligned already).
This increases code size slightly, but since many instructions that were 32-bit in ARM are now 16-bit, the overall code size is still smaller.
-Aligning node entries has no effect on the program's efficiency, since the \ual{nop} instruction that is inserted above the entry is never executed.
+Aligning node entries has no effect on the program's efficiency since the \ual{nop} instruction that is inserted above the entry is never executed.
\subsection{Other solutions}
\label{sec:code-addresses:other-solutions}