This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
per-callframe constants segment layout: | |
constants segment starts with a list of fixed-width pointers. I/N entries are stored directly. S/P entries are pointers to later in the constants segment | |
The data segment has a couple options. It can be appended after the constants segment (either on the next page or immediately after), with the constants data being marked read-only. Alternately, it can just be another segment attached to a special register. | |
If callframes are analogous to subs, the constants and data segment can be analogous to lexical data. | |
If callframes are analogous to subs, how will recursion work? | |
* clone a callframe (when? before entering ( -> no state) or after entering (less waste, leftover state)) | |
* need to work out calling conventions |