3 times faster MT19937 in GCC

Правка en1, от oToToT, 2022-10-28 22:11:56

TL; DR: #include <ext/random> and use __gnu_cxx::sfmt19937 just as std::mt19937.

Hi all,

I'm here to share a thing that seems not that well-known in the whole community.

I test the two codes below in the Codeforces' custom test with input 1000000000

sfmt19937
mt19937

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en3 Английский oToToT 2022-10-28 22:33:41 0 (published)
en2 Английский oToToT 2022-10-28 22:33:02 724
en1 Английский oToToT 2022-10-28 22:11:56 1050 Initial revision (saved to drafts)