Re: pgbench progress report improvements - split 2

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: pgbench progress report improvements - split 2
Дата
Msg-id alpine.DEB.2.02.1309242032330.8198@sto
обсуждение исходный текст
Ответ на Re: pgbench progress report improvements - split 2  (Noah Misch <noah@leadboat.com>)
Ответы Re: pgbench progress report improvements - split 2  (Noah Misch <noah@leadboat.com>)
Список pgsql-hackers
Hello Noah,

> meet all those goals simultaneously with simpler code, can we not?
>
>         int64 wait = (int64) (throttle_delay *
>             Min(7.0, -log(1 - pg_erand48(thread->random_state))));

If you truncate roughly the multipler, as it is done here with "min", you 
necessarily create a bias, my random guess would be a 0.5% under 
estimation, but maybe it is more... Thus you would have to compute and the 
correcting factor as well. Its computation is a little bit less easy than 
with the quantized formula where I just used a simple SUM, and you have to 
really do the maths here. So I would keep the simple solution, but it is 
fine with me if you do the maths!

-- 
Fabien.



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: FW: REVIEW: Allow formatting in log_line_prefix
Следующее
От: Stephen Frost
Дата:
Сообщение: Re: record identical operator