X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;ds=sidebyside;f=Tools%2Fnativelib%2Fthreads.c;h=dafdc404ce6d87cac00a625a683266ebf6cb55c6;hb=8a3c7218fb65c46c0876b7033b732188be91ae03;hp=cc508fbf280a697bc53f437585753cdd17daa356;hpb=50a98c40481c6d1df267f4631228e9a4d107fe74;p=tpg%2Facess2.git diff --git a/Tools/nativelib/threads.c b/Tools/nativelib/threads.c index cc508fbf..dafdc404 100644 --- a/Tools/nativelib/threads.c +++ b/Tools/nativelib/threads.c @@ -5,6 +5,7 @@ * threads.c * - Threads handling */ +#define DEBUG 0 #include #include #include @@ -84,6 +85,7 @@ void Threads_AddActive(tThread *Thread) { Thread->Status = THREAD_STAT_ACTIVE; // Increment state-change semaphore + LOG("Waking %p(%i %s)", Thread, Thread->TID, Thread->ThreadName); Threads_int_SemSignal(Thread->WaitSemaphore); } @@ -149,6 +151,7 @@ void Threads_int_WaitForStatusEnd(enum eThreadStatus Status) Log_Warning("Threads", "Thread %p(%i %s) rescheduled while in %s state", us, us->TID, us->ThreadName, casTHREAD_STAT[Status]); } + LOG("%p(%i %s) Awake", us, us->TID, us->ThreadName); } int Threads_int_Sleep(enum eThreadStatus Status, void *Ptr, int Num, tThread **ListHead, tThread **ListTail, tShortSpinlock *Lock)