Clean up g_thread_yield implementation