Guide to Random Number Generation in C++ - Adrien Devresse - C++Now 2024

  Рет қаралды 1,814

CppNow

CppNow

Күн бұрын

Пікірлер: 11
@mytech6779
@mytech6779 2 ай бұрын
Standard American English is my native language. I think I got about ⅔ of this of this talk because the French accent is very heavy. However, that is enough to know that it is a useful presentation and to give me plenty of seeds to generate the missing pieces with additional study.
@adev5983
@adev5983 2 ай бұрын
Hi Everybody, Speaker here: If you have any question, do not hesitate to ask. I will try my best to answer. If there is any confusion due to the wording/accent, feel free to ask too. Note: I have very little patience for the trolls: any agressive comment will be simply ignored.
@LeDabe
@LeDabe 2 ай бұрын
I tend to like ChaCha for its capability of generating a quality random stream of bits (its on par with AES). Also, when you say CBRNG do not have state, its not really right, every PRNG apply a function to an input and produce an output. For some of such function, that input is a key and counter (CBRNG), for other, its multiple integers, say 2 uint64t for Xoroshiro128p. In the case of Xoroshiro128p, you could have one of the uint64t be the key, and the other be the counter (though I can't recommend that).
@adev5983
@adev5983 2 ай бұрын
> I tend to like ChaCha for its capability of generating a quality random stream of bits ChaCha is definitively a good choice if you can afford the performance cost of using a real stream cipher. > Also, when you say CBRNG do not have state, its not really right Yes and no :) They indeed have a state but their state is entirely predictable. Like you say, it has a counter that can be reconstructed (e.g based on a time step in a simulation) and a key that can be derivated. Like I mentioned in the talk, jumping to any state in a CBRNG is O(1). You indeed could do the same with a xorshift family RNGs, but like you point out: it would be unsafe. At the opposite, it is safe to do with a CBRNG.
@japedr
@japedr 2 ай бұрын
Why not considering xorshiro, xorshift or PCG? State size is super important for performance, because of cache friendliness implications.
@adev5983
@adev5983 2 ай бұрын
Hi, Speaker here. There is a little mention of xorshift and worwow during the QnA session at the end. In short : - Threefry or ARS have a 128bits state which is similar in size to a xorshift of reasonnable quality and most good PCGs. - CBRNGs tend to be more fool proof than PCGs algorithms. - They also tend to have better random quality than xorshifts. - The fact that CBRNGs can be used in a stateless mode make them very suitable for massively parallel algorithm (common in scientific computing).
@japedr
@japedr Ай бұрын
@@adev5983 Thanks for replying. That's pretty nice.
@ladnir
@ladnir 2 ай бұрын
All aes keys are very strong for non cryptographic algorithms. Idk about ars. But probably fine.
@27182818284590452354
@27182818284590452354 2 ай бұрын
The accent is so thick it's headache-inducing to listen to, especially for non-native speakers.
@monkyyy0
@monkyyy0 2 ай бұрын
> comparing c to c++ apis > its a good thing c++ is like that into the trash you go
FOREVER BUNNY
00:14
Natan por Aí
Рет қаралды 26 МЛН
МЕНЯ УКУСИЛ ПАУК #shorts
00:23
Паша Осадчий
Рет қаралды 5 МЛН
Simple Artificial Neural Network entirely in assembly language
30:54
Computing Mongoose
Рет қаралды 8 М.