Skip to content
This repository has been archived by the owner on Oct 15, 2018. It is now read-only.

Consider specializing seed_from_u64 for Pcg32 #6

Open
vks opened this issue Oct 4, 2018 · 1 comment
Open

Consider specializing seed_from_u64 for Pcg32 #6

vks opened this issue Oct 4, 2018 · 1 comment

Comments

@vks
Copy link

vks commented Oct 4, 2018

The default implementation of seed_from_u64 already uses the same algorithm, which could result in unwanted correlations. We should consider to provide a different implementation to avoid this problem.

@dhardy
Copy link
Member

dhardy commented Oct 4, 2018

I don't believe this is an issue since the XSH RR output function is not linear, and also not injective (output is half the size of input). Further, a Pcg32 PRNG seeded like this would have a stream set, which has a very low chance of being 11634580027462260723 (the increment used by seed_from_u64). Thus I don't think there could be any issues more significant than weaknesses in Pcg32 itself.

@imneme are you aware of any issues seeding a Pcg32 PRNG from another Pcg32 PRNG?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants