util/rand_xor: make it clear that {,s_}rand_xorshift128plus take *exactly 2* uint64_t
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/2316>
This commit is contained in:

committed by
Marge Bot

parent
576bff5c73
commit
f50f26325f
@@ -41,7 +41,7 @@
|
|||||||
* to the public domain.
|
* to the public domain.
|
||||||
*/
|
*/
|
||||||
uint64_t
|
uint64_t
|
||||||
rand_xorshift128plus(uint64_t *seed)
|
rand_xorshift128plus(uint64_t seed[2])
|
||||||
{
|
{
|
||||||
uint64_t *s = seed;
|
uint64_t *s = seed;
|
||||||
|
|
||||||
@@ -55,7 +55,7 @@ rand_xorshift128plus(uint64_t *seed)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
s_rand_xorshift128plus(uint64_t *seed, bool randomised_seed)
|
s_rand_xorshift128plus(uint64_t seed[2], bool randomised_seed)
|
||||||
{
|
{
|
||||||
if (!randomised_seed)
|
if (!randomised_seed)
|
||||||
goto fixed_seed;
|
goto fixed_seed;
|
||||||
|
@@ -29,9 +29,9 @@
|
|||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
uint64_t
|
uint64_t
|
||||||
rand_xorshift128plus(uint64_t *seed);
|
rand_xorshift128plus(uint64_t seed[2]);
|
||||||
|
|
||||||
void
|
void
|
||||||
s_rand_xorshift128plus(uint64_t *seed, bool randomised_seed);
|
s_rand_xorshift128plus(uint64_t seed[2], bool randomised_seed);
|
||||||
|
|
||||||
#endif /* RAND_XOR_H */
|
#endif /* RAND_XOR_H */
|
||||||
|
Reference in New Issue
Block a user