[Coin-discuss] user time vs. system time
Tobias Achterberg
achterberg at zib.de
Wed Mar 2 10:00:37 EST 2005
Hi Brady,
as far as I know, the problem with system time is that it depends on IO operations and on other threads that are running
in parallel on your machine. That is, depending on the other tasks, the system time can vary a lot. The user time gives
a more appropriate measurement for what time was used to run your algorithm.
However, even the user time can be influenced by other tasks and the scheduling algorithm employed by the operating
system. For example, the processor cache is filled with (for your application) useless data, after your application was
interrupted due to preemption.
On Pentium IV processors with hyperthreading, time measurement is VERY sensitive to other tasks running on your machine.
My experience is that having a second computational task running, the measured user time can increase by up to 50%
(rough guess) compared to the case, where only one application is running.
Greetings, Tobi
Brady Hunsaker wrote:
> I'm teaching a computational optimization class, and I realized I need
> to talk about measuring time correctly.
>
> What I have always done, and what CoinCpuTime does, is to measure only
> the user time. But I realized that I don't have a good explanation for
> why system time is excluded. I couldn't find one in a quick web search
> either.
>
> Is the idea that system time depends on kernel code rather than the user
> code, so we should ignore it? But why is that? Is it ever appropriate
> to include system time in computational results? (If so, we should add
> this capability to CoinTime.)
>
> Thanks,
> Brady
> _______________________________________________
> Coin-discuss mailing list
> Coin-discuss at list.coin-or.org
> http://list.coin-or.org/mailman/listinfo/coin-discuss
--
Tobias Achterberg Konrad-Zuse-Zentrum fuer
Informationstechnik Berlin
Tel: +49 (0)30 84185-301 Takustr. 7
Email: achterberg at zib.de D-14195 Berlin, Germany
More information about the Coin-discuss
mailing list