I'm still not over this. In addition to UB the Verilog $random C code also relies on some IDB. 1/https://twitter.com/oe1cxw/status/870972176421330945 …
-
-
The latter is ridiculous considering that this is a function that has only integers as in- and outputs! (old seed, new seed, rand val)
-
But internally it first creates a uniformly distributed float random value in range (INT_MIN INT_MAX) and then converts that one to an int.
- Show replies
New conversation -
-
-
Looks like the creators ignored all recommendations for PRNGs found in Numerical Recipes.
-
I'd assume that code predates at least the C version of Numerical Recipes. (Which is not very good imo anyways. C Arrays are 0 indexed!!! :)
- Show replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.