From a91cc8496bf4ea7fe1e3ad9d97836152f3939ffa Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Wed, 7 Jun 2006 12:44:07 +0000 Subject: Gather timing stats for a Task when it completes. Previously we did this just for workers, now we do it for the main thread and for forkOS threads too. --- rts/posix/OSThreads.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'rts/posix/OSThreads.c') diff --git a/rts/posix/OSThreads.c b/rts/posix/OSThreads.c index 07bd762130..cff37824cb 100644 --- a/rts/posix/OSThreads.c +++ b/rts/posix/OSThreads.c @@ -16,6 +16,7 @@ #if defined(THREADED_RTS) #include "OSThreads.h" #include "RtsUtils.h" +#include "Task.h" #if HAVE_STRING_H #include @@ -140,6 +141,7 @@ forkOS_createThreadWrapper ( void * entry ) Capability *cap; cap = rts_lock(); cap = rts_evalStableIO(cap, (HsStablePtr) entry, NULL); + taskTimeStamp(myTask()); rts_unlock(cap); return NULL; } -- cgit v1.2.1