|
@@ -1288,6 +1288,11 @@ HL_API void hl_gc_set_flags( int f ) {
|
|
gc_flags = f;
|
|
gc_flags = f;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+HL_API void hl_set_thread_flags( int flags, int mask ) {
|
|
|
|
+ hl_thread_info *t = hl_get_thread();
|
|
|
|
+ t->flags = (t->flags & ~mask) | flags;
|
|
|
|
+}
|
|
|
|
+
|
|
HL_API void hl_gc_profile( bool b ) {
|
|
HL_API void hl_gc_profile( bool b ) {
|
|
if( b )
|
|
if( b )
|
|
gc_flags |= GC_PROFILE;
|
|
gc_flags |= GC_PROFILE;
|
|
@@ -1419,3 +1424,4 @@ DEFINE_PRIM(_I32, gc_get_flags, _NO_ARG);
|
|
DEFINE_PRIM(_VOID, gc_set_flags, _I32);
|
|
DEFINE_PRIM(_VOID, gc_set_flags, _I32);
|
|
DEFINE_PRIM(_DYN, debug_call, _I32 _DYN);
|
|
DEFINE_PRIM(_DYN, debug_call, _I32 _DYN);
|
|
DEFINE_PRIM(_VOID, blocking, _BOOL);
|
|
DEFINE_PRIM(_VOID, blocking, _BOOL);
|
|
|
|
+DEFINE_PRIM(_VOID, set_thread_flags, _I32 _I32);
|