diff options
Diffstat (limited to 'src/lj_obj.h')
-rw-r--r-- | src/lj_obj.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lj_obj.h b/src/lj_obj.h index 137a04b2..7890e54b 100644 --- a/src/lj_obj.h +++ b/src/lj_obj.h | |||
@@ -321,6 +321,10 @@ typedef struct GCproto { | |||
321 | /* Top bits used for counting created closures. */ | 321 | /* Top bits used for counting created closures. */ |
322 | #define PROTO_CLCOUNT 0x20 /* Base of saturating 3 bit counter. */ | 322 | #define PROTO_CLCOUNT 0x20 /* Base of saturating 3 bit counter. */ |
323 | #define PROTO_CLC_BITS 3 | 323 | #define PROTO_CLC_BITS 3 |
324 | #define PROTO_CLC_POLY (3*PROTO_CLCOUNT) /* Polymorphic threshold. */ | ||
325 | |||
326 | #define PROTO_UV_LOCAL 0x8000 /* Upvalue for local slot. */ | ||
327 | #define PROTO_UV_IMMUTABLE 0x4000 /* Immutable upvalue. */ | ||
324 | 328 | ||
325 | #define proto_kgc(pt, idx) \ | 329 | #define proto_kgc(pt, idx) \ |
326 | check_exp((uintptr_t)(intptr_t)(idx) >= (uintptr_t)-(intptr_t)(pt)->sizekgc, \ | 330 | check_exp((uintptr_t)(intptr_t)(idx) >= (uintptr_t)-(intptr_t)(pt)->sizekgc, \ |
@@ -342,7 +346,7 @@ typedef struct GCproto { | |||
342 | typedef struct GCupval { | 346 | typedef struct GCupval { |
343 | GCHeader; | 347 | GCHeader; |
344 | uint8_t closed; /* Set if closed (i.e. uv->v == &uv->u.value). */ | 348 | uint8_t closed; /* Set if closed (i.e. uv->v == &uv->u.value). */ |
345 | uint8_t unused; | 349 | uint8_t immutable; /* Immutable value. */ |
346 | union { | 350 | union { |
347 | TValue tv; /* If closed: the value itself. */ | 351 | TValue tv; /* If closed: the value itself. */ |
348 | struct { /* If open: double linked list, anchored at thread. */ | 352 | struct { /* If open: double linked list, anchored at thread. */ |