]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Move (commented out) call to VG_(tm_thread_switchto) to VG_(set_running) so
authorTom Hughes <tom@compton.nu>
Wed, 27 Jul 2005 23:04:28 +0000 (23:04 +0000)
committerTom Hughes <tom@compton.nu>
Wed, 27 Jul 2005 23:04:28 +0000 (23:04 +0000)
that it is always called when a new thread starts running. Add in a direct
call to VG_TRACK to issue a thread_run event at the same place until thread
modelling is working again.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@4287

coregrind/m_scheduler/scheduler.c

index e93d220a87875761399e98c20e07d85ede9eace6..41b41acce81cc881d4cd9ce67754f78cdbcd2d6d 100644 (file)
@@ -203,6 +203,10 @@ void VG_(set_running)(ThreadId tid)
 
    if (VG_(clo_trace_sched))
       print_sched_event(tid, "now running");
+
+   // While thre modeling is disable, issue thread_run events here
+   // VG_(tm_thread_switchto)(tid);
+   VG_TRACK( thread_run, tid );
 }
 
 /* 
@@ -626,7 +630,6 @@ VgSchedReturnCode VG_(scheduler) ( ThreadId tid )
         VG_(set_sleeping)(tid, VgTs_Yielding);
         /* nothing */
         VG_(set_running)(tid);
-        //VG_(tm_thread_switchto)(tid);
 
         /* OK, do some relatively expensive housekeeping stuff */
         scheduler_sanity(tid);