Re[2]: Joels Time Leak

Hello Simon, Wednesday, January 04, 2006, 7:33:22 PM, you wrote:
The minimum time between context switches is 20 milliseconds.
SM> Sure, there's no reason why we couldn't do this. Of course, even SM> idle Haskell processes will be ticking away in the background, so SM> there's a reason not to make the interval too short. What do SM> you think is reasonable?
Simon, the talk is about changing GHC _tick_, which is a _minimal_ possible context switch interval
SM> Yes, I know. in this case, why you say that idle processes will be ticking in background? it's entirely up to program writers/users if they wants to decrease this interval. by default switches will occur in the same 20 ms, lesser tick will have no impact on ordinary programs as long as default switching time will be not changed -- Best regards, Bulat mailto:bulatz@HotPOP.com

Bulat Ziganshin wrote:
Hello Simon,
Wednesday, January 04, 2006, 7:33:22 PM, you wrote:
The minimum time between context switches is 20 milliseconds.
SM> Sure, there's no reason why we couldn't do this. Of course, even SM> idle Haskell processes will be ticking away in the background, so SM> there's a reason not to make the interval too short. What do SM> you think is reasonable?
Simon, the talk is about changing GHC _tick_, which is a _minimal_ possible context switch interval
SM> Yes, I know.
in this case, why you say that idle processes will be ticking in background? it's entirely up to program writers/users if they wants to decrease this interval. by default switches will occur in the same 20 ms, lesser tick will have no impact on ordinary programs as long as default switching time will be not changed
It will have an impact, because the tick signal has to be delivered to the process and the signal handler run. The impact on CPU time is small, but could be noticeable if we were to choose too small an interval. Furthermore, the ticker prevents idle Haskell processes from being completely swapped out (that problem already exists). Cheers, Simon

Hello Simon, Thursday, January 05, 2006, 3:40:27 PM, you wrote:
SM> Sure, there's no reason why we couldn't do this. Of course, even SM> idle Haskell processes will be ticking away in the background, so SM> there's a reason not to make the interval too short. What do SM> you think is reasonable?
SM> It will have an impact, because the tick signal has to be delivered to SM> the process and the signal handler run. you are saying about C callback which would be called by OS to count ticks? SM> The impact on CPU time is SM> small, but could be noticeable if we were to choose too small an SM> interval. Furthermore, the ticker prevents idle Haskell processes from SM> being completely swapped out (that problem already exists). having ticks of 0.02 sec or 0.000002 sec doesn't change anything for this problem i think that reasonable tick would be in range of 10-100 microseconds, so what program with 10k threads (reasonable maximum with current technologies state) can give slice to each thread in 0.1-1 seconds -- Best regards, Bulat mailto:bulatz@HotPOP.com
participants (2)
-
Bulat Ziganshin
-
Simon Marlow