Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
cmucl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Carl Shapiro
cmucl
Commits
3f02e304
Commit
3f02e304
authored
20 years ago
by
cwang
Browse files
Options
Downloads
Patches
Plain Diff
make symbol and NIL layouts up-to-date
parent
6779af26
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/internals/object.tex
+10
-24
10 additions, 24 deletions
docs/internals/object.tex
with
10 additions
and
24 deletions
docs/internals/object.tex
+
10
−
24
View file @
3f02e304
...
@@ -296,15 +296,11 @@ already has to deal with rounding up various objects to dual-word alignment.
...
@@ -296,15 +296,11 @@ already has to deal with rounding up various objects to dual-word alignment.
Symbol data-block has the following format:
Symbol data-block has the following format:
\begin{verbatim}
\begin{verbatim}
-------------------------------------------------------
-------------------------------------------------------
|
7
(data-block words) | Symbol Type (8 bits) |
|
5
(data-block words) | Symbol Type (8 bits) |
-------------------------------------------------------
-------------------------------------------------------
| Value Descriptor
|
|
Value Descriptor |
-------------------------------------------------------
-------------------------------------------------------
| Function Pointer |
| Hash Value (x86/amd64/sparc) Unused (other arch.) |
-------------------------------------------------------
| Raw Function Address |
-------------------------------------------------------
| Setf Function |
-------------------------------------------------------
-------------------------------------------------------
| Property List |
| Property List |
-------------------------------------------------------
-------------------------------------------------------
...
@@ -314,14 +310,8 @@ Symbol data-block has the following format:
...
@@ -314,14 +310,8 @@ Symbol data-block has the following format:
-------------------------------------------------------
-------------------------------------------------------
\end{verbatim}
\end{verbatim}
Most of these slots are self-explanatory given what symbols must do in Common
All of these slots are self-explanatory given what symbols must do in Common
Lisp, but a couple require comments. We added the Raw Function Address slot to
Lisp.
speed up named call which is the most common calling convention. This is a
non-descriptor slot, but since objects are dual word aligned, the value
inherently has fixnum low-tag bits. The GC method for symbols must know to
update this slot. The Setf Function slot is currently unused, but we had an
extra slot due to adding Raw Function Address since objects must be dual-word
aligned.
The issues with nil are that we want it to act like a symbol, and we need list
The issues with nil are that we want it to act like a symbol, and we need list
operations such as CAR and CDR to be fast on it. CMU Common Lisp solves this
operations such as CAR and CDR to be fast on it. CMU Common Lisp solves this
...
@@ -329,17 +319,13 @@ by putting nil as the first object in static space, where other global values
...
@@ -329,17 +319,13 @@ by putting nil as the first object in static space, where other global values
reside, so it has a known address in the system:
reside, so it has a known address in the system:
\begin{verbatim}
\begin{verbatim}
------------------------------------------------------- <-- space
------------------------------------------------------- <-- space
|
0
| start
|
6 (data-block words)
|
0 | start
-------------------------------------------------------
-------------------------------------------------------
|
7
(data-block words) | Symbol Type (8 bits) |
|
0
(data-block words) | Symbol Type (8 bits) |
------------------------------------------------------- <-- nil
------------------------------------------------------- <-- nil
| Value/CAR |
| Value/CAR |
-------------------------------------------------------
-------------------------------------------------------
| Definition/CDR |
| Hash Value/CDR |
-------------------------------------------------------
| Raw Function Address |
-------------------------------------------------------
| Setf Function |
-------------------------------------------------------
-------------------------------------------------------
| Property List |
| Property List |
-------------------------------------------------------
-------------------------------------------------------
...
@@ -352,7 +338,7 @@ reside, so it has a known address in the system:
...
@@ -352,7 +338,7 @@ reside, so it has a known address in the system:
\end{verbatim}
\end{verbatim}
In addition, we make the list typed pointer to nil actually point past the
In addition, we make the list typed pointer to nil actually point past the
header word of the nil symbol data-block. This has usefulness explained below.
header word of the nil symbol data-block. This has usefulness explained below.
The value and
definition
of nil are nil. Therefore, any reference to nil used
The value and
hash-value
of nil are nil. Therefore, any reference to nil used
as a list has quick list type checking, and CAR and CDR can go right through
as a list has quick list type checking, and CAR and CDR can go right through
the first and second words as if nil were a cons object.
the first and second words as if nil were a cons object.
...
@@ -364,7 +350,7 @@ type tag, but nil points four additional bytes into its symbol data-block.
...
@@ -364,7 +350,7 @@ type tag, but nil points four additional bytes into its symbol data-block.
;;;;
Array Headers
.
\section
{
Array Headers
}
The array-header data-block has the following format:
The array-header data-block has the following format:
\begin{verbatim}
\begin{verbatim}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment