Major refactoring. Major problems!
On the right path but it doesn't work yet.
This commit is contained in:
parent
ae8ba67ed7
commit
9937f344dc
20 changed files with 695 additions and 506 deletions
|
|
@ -34,20 +34,16 @@
|
|||
#define NAMESPACETAG "NMSP"
|
||||
#define NAMESPACETV 0
|
||||
|
||||
/*
|
||||
* a stack frame.
|
||||
*/
|
||||
#define STACKFRAMETAG "STAK"
|
||||
#define STACKFRAMETV
|
||||
/*
|
||||
* a vector of cons pointers.
|
||||
*/
|
||||
#define VECTORTAG "VECT"
|
||||
#define VECTORTV 0
|
||||
|
||||
#define pointer_to_vso(pointer)(vectorpointp(pointer)? pointer2cell(pointer).payload.vectorp.address : 0)
|
||||
#define pointer_to_vso(pointer)((vectorpointp(pointer)? pointer2cell(pointer).payload.vectorp.address : NULL))
|
||||
#define vso_get_vecp(vso)((vso->header.vecp))
|
||||
|
||||
struct cons_pointer make_vso( char *tag, int64_t payload_size );
|
||||
struct cons_pointer make_vso( char *tag, uint64_t payload_size );
|
||||
|
||||
struct vector_space_header {
|
||||
union {
|
||||
|
|
@ -62,8 +58,10 @@ struct vector_space_header {
|
|||
struct cons_pointer vecp; /* back pointer to the vector pointer
|
||||
* which uniquely points to this vso */
|
||||
uint64_t size; /* the size of my payload, in bytes */
|
||||
char mark; /* mark bit for marking/sweeping the
|
||||
* heap (not in this version) */
|
||||
};
|
||||
|
||||
struct vector_space_object {
|
||||
struct vector_space_header header;
|
||||
char payload; /* we'll malloc `size` bytes for payload,
|
||||
* `payload` is just the first of these.
|
||||
* TODO: this is almost certainly not
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue