X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=rts%2FSchedule.h;h=5f669b3d83a7b33bd98bcf5b9b6868903953c313;hb=0b2de03568d3acf8143ff7f6dde103099bf8ff1a;hp=378bd68c66219041440a8404805dd432b13d460d;hpb=a2a67cd520b9841114d69a87a423dabcb3b4368e;p=ghc-hetmet.git diff --git a/rts/Schedule.h b/rts/Schedule.h index 378bd68..5f669b3 100644 --- a/rts/Schedule.h +++ b/rts/Schedule.h @@ -12,7 +12,9 @@ #include "rts/OSThreads.h" #include "Capability.h" -#include "eventlog/EventLog.h" +#include "Trace.h" + +BEGIN_RTS_PRIVATE /* initScheduler(), exitScheduler() * Called from STG : no @@ -124,7 +126,10 @@ void performPendingThrowTos (StgTSO *); * NOTE: tso->link should be END_TSO_QUEUE before calling this macro. * ASSUMES: cap->running_task is the current task. */ -INLINE_HEADER void +EXTERN_INLINE void +appendToRunQueue (Capability *cap, StgTSO *tso); + +EXTERN_INLINE void appendToRunQueue (Capability *cap, StgTSO *tso) { ASSERT(tso->_link == END_TSO_QUEUE); @@ -134,7 +139,7 @@ appendToRunQueue (Capability *cap, StgTSO *tso) setTSOLink(cap, cap->run_queue_tl, tso); } cap->run_queue_tl = tso; - postEvent (cap, EVENT_THREAD_RUNNABLE, tso->id, 0); + traceSchedEvent (cap, EVENT_THREAD_RUNNABLE, tso, 0); } /* Push a thread on the beginning of the run queue. @@ -239,5 +244,7 @@ emptyThreadQueues(Capability *cap) #endif /* !IN_STG_CODE */ +END_RTS_PRIVATE + #endif /* SCHEDULE_H */