mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-24 04:25:06 +02:00
Definitions to support C host functions
This commit is contained in:
parent
80ac3ef86f
commit
c09851a3de
2 changed files with 7 additions and 0 deletions
2
gc.c
2
gc.c
|
@ -2669,6 +2669,8 @@ void gc_thread_data_init(gc_thread_data * thd, int mut_num, char *stack_base,
|
|||
(1 - STACK_GROWTH_IS_DOWNWARD));
|
||||
exit(1);
|
||||
}
|
||||
thd->pc = 0;
|
||||
thd->args = calloc(MAX_C_ARGS, sizeof(object));
|
||||
thd->stack_traces = calloc(MAX_STACK_TRACES, sizeof(char *));
|
||||
thd->stack_trace_idx = 0;
|
||||
thd->stack_prev_frame = NULL;
|
||||
|
|
|
@ -340,8 +340,13 @@ struct gc_thread_data_t {
|
|||
object exception_handler_stack;
|
||||
// Parameter object data
|
||||
object param_objs;
|
||||
// Support for host functions
|
||||
int pc;
|
||||
object *args;
|
||||
};
|
||||
|
||||
#define MAX_C_ARGS 128
|
||||
|
||||
/* GC prototypes */
|
||||
void gc_initialize(void);
|
||||
void gc_add_mutator(gc_thread_data * thd);
|
||||
|
|
Loading…
Add table
Reference in a new issue