CACAO
Functions | Variables
thread-none.cpp File Reference

Go to the source code of this file.

Functions

void threads_impl_preinit ()
 
void threads_impl_init ()
 
void threads_impl_thread_start (threadobject *thread, functionptr f)
 
void threads_set_thread_priority (threadobject *t, int priority)
 
bool thread_detach_current_thread (void)
 Detaches the current thread from the VM. More...
 
bool threads_suspend_thread (threadobject *thread, SuspendReason reason)
 Suspend the passed thread. More...
 
bool threads_resume_thread (threadobject *thread, SuspendReason reason)
 Resumes execution of the passed thread. More...
 
void threads_impl_clear_heap_pointers (threadobject *t)
 
void threads_suspend_ack ()
 
void threads_join_all_threads ()
 
void threads_impl_thread_clear (threadobject *t)
 
void threads_impl_thread_reuse (threadobject *t)
 
void threads_thread_interrupt (threadobject *t)
 
void threads_sleep (int64_t millis, int32_t nanos)
 
void threads_wait_with_timeout_relative (threadobject *thread, s8 millis, s4 nanos)
 
void threads_park (bool absolute, int64_t nanos)
 Park the current thread for the specified amount of time or until a specified deadline. More...
 
void threads_unpark (threadobject *t)
 Unpark the specified thread. More...
 
void threads_yield (void)
 
intptr_t threads_get_tid (threadobject *t)
 

Variables

threadobjectthread_current
 

Function Documentation

bool thread_detach_current_thread ( void  )

Detaches the current thread from the VM.

Returns
true on success, false otherwise

Definition at line 86 of file thread-none.cpp.

intptr_t threads_get_tid ( threadobject t)

Definition at line 392 of file thread-none.cpp.

void threads_impl_clear_heap_pointers ( threadobject t)

Definition at line 239 of file thread-none.cpp.

void threads_impl_init ( void  )

Definition at line 58 of file thread-none.cpp.

void threads_impl_preinit ( void  )

Definition at line 52 of file thread-none.cpp.

void threads_impl_thread_clear ( threadobject t)

Definition at line 258 of file thread-none.cpp.

void threads_impl_thread_reuse ( threadobject t)

Definition at line 298 of file thread-none.cpp.

void threads_impl_thread_start ( threadobject thread,
functionptr  f 
)

Definition at line 64 of file thread-none.cpp.

void threads_join_all_threads ( void  )

Definition at line 253 of file thread-none.cpp.

void threads_park ( bool  absolute,
int64_t  nanos 
)

Park the current thread for the specified amount of time or until a specified deadline.

Parameters
absoluteIs the time in nanos a deadline or a duration?
nanosNanoseconds to park (absolute=false) or deadline in milliseconds (absolute=true)

Definition at line 373 of file thread-none.cpp.

bool threads_resume_thread ( threadobject thread,
SuspendReason  reason 
)

Resumes execution of the passed thread.

Parameters
threadThe thread to be resumed.
reasonReason for suspending the given thread.
Returns
True of operation was successful, false otherwise.

Definition at line 220 of file thread-none.cpp.

void threads_set_thread_priority ( threadobject t,
int  priority 
)

Definition at line 77 of file thread-none.cpp.

void threads_sleep ( int64_t  millis,
int32_t  nanos 
)

Definition at line 320 of file thread-none.cpp.

void threads_suspend_ack ( )

Definition at line 248 of file thread-none.cpp.

bool threads_suspend_thread ( threadobject thread,
SuspendReason  reason 
)

Suspend the passed thread.

Execution of that thread stops until the thread is explicitly resumed again.

Parameters
threadThe thread to be suspended.
reasonReason for suspending the given thread.
Returns
True of operation was successful, false otherwise.

Definition at line 194 of file thread-none.cpp.

void threads_thread_interrupt ( threadobject t)

Definition at line 305 of file thread-none.cpp.

void threads_unpark ( threadobject t)

Unpark the specified thread.

Parameters
tThe thread to unpark.

Definition at line 380 of file thread-none.cpp.

void threads_wait_with_timeout_relative ( threadobject thread,
s8  millis,
s4  nanos 
)

Definition at line 362 of file thread-none.cpp.

void threads_yield ( void  )

Definition at line 386 of file thread-none.cpp.

Variable Documentation

threadobject* thread_current

Definition at line 41 of file thread-none.cpp.