Skip to content

Commit

Permalink
Update for Julia GC API changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
rbehrends committed Jun 4, 2018
1 parent 7f5ede2 commit 98383bd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/julia_gc.c
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ void InitFreeFuncBag(UInt type, TNumFreeFuncBags finalizer_func)
TabFreeFuncBags[type] = finalizer_func;
}

void JFinalizer(void * obj)
void JFinalizer(jl_value_t * obj)
{
BagHeader * hdr = (BagHeader *)obj;
Bag contents = (Bag)(hdr + 1);
Expand Down Expand Up @@ -402,7 +402,7 @@ void InitMarkFuncBags(UInt type, TNumMarkFuncBags mark_func)

static inline int JMark(void * obj)
{
return jl_gc_mark_queue_obj(JContext, obj);
return jl_gc_mark_queue_obj(JContext, (jl_value_t *)obj);
}

// Overview of conservative stack scanning
Expand Down Expand Up @@ -562,17 +562,17 @@ static inline int GcOld(void * p)

// the Julia marking function for master pointer objects (i.e., this function
// is called by the Julia GC whenever it marks a GAP master pointer object)
static void JMarkMPtr(void * obj)
static void JMarkMPtr(int tid, jl_value_t * obj)
{
if (!*(void **)obj)
return;
if (JMark(BAG_HEADER(obj)) && GcOld(obj))
if (JMark(BAG_HEADER((Bag)obj)) && GcOld(obj))
jl_gc_mark_push_remset(JContext, obj, 1);
}

// the Julia marking function for bags (i.e., this function is called by the
// Julia GC whenever it marks a GAP bag object)
static void JMarkBag(void * obj)
static void JMarkBag(int tid, jl_value_t * obj)
{
BagHeader * hdr = (BagHeader *)obj;
Bag contents = (Bag)(hdr + 1);
Expand Down

0 comments on commit 98383bd

Please sign in to comment.