Cygwin: posix timers: reimplement using OS timer
- Rename files timer.* to posix_timer.*. - Reimplement using an OS timer rather than a handcrafted wait loop. - Use a Slim R/W Lock for synchronization. - Drop timer chaining. It doesn't server a purpose since all timers are local only. - Rename ttstart to itimer_tracker to better reflect its purpose. It's not the anchor for a timer chain anymore anyway. - Drop fixup_timers_after_fork. Everything is process-local, nothing gets inherited. - Rename timer_tracker::disarm_event to disarm_overrun_event for better readability. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
		| @@ -21,7 +21,7 @@ details. */ | ||||
| #include "dtable.h" | ||||
| #include "cygheap.h" | ||||
| #include "cygwait.h" | ||||
| #include "timer.h" | ||||
| #include "posix_timer.h" | ||||
|  | ||||
| #define _SA_NORESTART	0x8000 | ||||
|  | ||||
| @@ -619,7 +619,7 @@ sigwait_common (const sigset_t *set, siginfo_t *info, PLARGE_INTEGER waittime) | ||||
| 		{ | ||||
| 		  timer_tracker *tt = (timer_tracker *) | ||||
| 				      _my_tls.infodata.si_tid; | ||||
| 		  _my_tls.infodata.si_overrun = tt->disarm_event (); | ||||
| 		  _my_tls.infodata.si_overrun = tt->disarm_overrun_event (); | ||||
| 		} | ||||
| 	      if (info) | ||||
| 		*info = _my_tls.infodata; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user