Attemping to add write barrier for set operations

This commit is contained in:
Justin Ethier 2015-11-17 23:03:11 -05:00
parent 4e30e6d551
commit e4c4148a74
2 changed files with 12 additions and 1 deletions

View file

@ -41,7 +41,8 @@ extern const object Cyc_EOF;
object cell_get(object cell);
#define global_set(glo,value) (glo=value)
#define global_set(glo,value) Cyc_global_set(data, (object *)&glo, value)
object Cyc_global_set(void *thd, object *glo, object value);
/* Variable argument count support

View file

@ -12,6 +12,16 @@
//int JAE_DEBUG = 0;
//int gcMoveCountsDEBUG[20] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
TODO: still not good enough, need to be smarter when marking grey objs that are
still on the stack (??). see reg-port in read.sld
object Cyc_global_set(void *thd, object *glo, object value)
{
gc_mut_update((gc_thread_data *)thd, *glo, value);
*(glo) = value;
return value;
}
/* Error checking section - type mismatch, num args, etc */
/* Type names to use for error messages */
const char *tag_names[21] = { \