It doesn't make sense to keep this struct thread_info in global.h, it causes difficulties to access its contents from hathreads.h, let's move it to the threads where it ought to have been created.