aboutsummaryrefslogtreecommitdiff
path: root/py/gc.h
diff options
context:
space:
mode:
authorDamien <damien.p.george@gmail.com>2013-10-21 23:45:08 +0100
committerDamien <damien.p.george@gmail.com>2013-10-21 23:45:08 +0100
commitdcced92c265ba67d467251cf8cacac427ec5951c (patch)
treea371b972e1a84a0b5fd6a06295896965af4b76f1 /py/gc.h
parentf48cf67108121e60560e45ee5f351031fdac7909 (diff)
Add mark-sweep garbage collector.
Diffstat (limited to 'py/gc.h')
-rw-r--r--py/gc.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/py/gc.h b/py/gc.h
new file mode 100644
index 000000000..e8bb80780
--- /dev/null
+++ b/py/gc.h
@@ -0,0 +1,8 @@
+void gc_init(void *start, void *end);
+void gc_collect_start();
+void gc_collect_root(void **ptrs, machine_uint_t len);
+void gc_collect_end();
+void gc_collect();
+void *gc_alloc(machine_uint_t n_bytes);
+machine_uint_t gc_nbytes(void *ptr_in);
+void *gc_realloc(void *ptr, machine_uint_t n_bytes);