Moving threading utils to poly.

This commit is contained in:
Ben Vanik
2014-07-10 23:51:28 -07:00
parent 9031d5f4a4
commit f24b45a07c
9 changed files with 119 additions and 14 deletions

View File

@@ -26,7 +26,7 @@ ThreadState::ThreadState(Runtime* runtime, uint32_t thread_id)
if (thread_id_ == UINT_MAX) {
// System thread. Assign the system thread ID with a high bit
// set so people know what's up.
uint32_t system_thread_handle = GetCurrentThreadId();
uint32_t system_thread_handle = poly::threading::current_thread_id();
thread_id_ = 0x80000000 | system_thread_handle;
}
backend_data_ = runtime->backend()->AllocThreadData();