Re: rand48 replacement

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: rand48 replacement
Дата
Msg-id alpine.DEB.2.22.394.2107060805140.3858351@pseudo
обсуждение исходный текст
Ответ на Re: rand48 replacement  (Yura Sokolov <y.sokolov@postgrespro.ru>)
Ответы Re: rand48 replacement
Список pgsql-hackers
Hello Yura,

> I believe most "range" values are small, much smaller than UINT32_MAX.
> In this case, according to [1] fastest method is Lemire's one (I'd take
> original version from [2]) [...]

Yep.

I share your point that the range is more often 32 bits.

However, I'm not enthousiastic at combining two methods depending on the 
range, the function looks complex enough without that, so I would suggest 
not to take this option. Also, the decision process adds to the average 
cost, which is undesirable. I would certainly select the unbias multiply 
method if we want a u32 range variant.

-- 
Fabien.



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

Предыдущее
От: Dipesh Pandit
Дата:
Сообщение: Re: .ready and .done files considered harmful
Следующее
От: Ronan Dunklau
Дата:
Сообщение: [PATCH] Use optimized single-datum tuplesort in ExecSort