projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0e99e09
)
PR fortran/91414 Bugfix for previous commit
author
Janne Blomqvist
<jb@gcc.gnu.org>
Tue, 13 Aug 2019 09:04:18 +0000
(12:04 +0300)
committer
Janne Blomqvist
<jb@gcc.gnu.org>
Tue, 13 Aug 2019 09:04:18 +0000
(12:04 +0300)
Correctly fill master_seed from os_seed.
From-SVN: r274365
libgfortran/intrinsics/random.c
patch
|
blob
|
history
diff --git
a/libgfortran/intrinsics/random.c
b/libgfortran/intrinsics/random.c
index cad21fedb5770371de42def84c2bf5ebc5f4c388..dd2c46e7ef57403a2edfbfefdbde8632607b9b73 100644
(file)
--- a/
libgfortran/intrinsics/random.c
+++ b/
libgfortran/intrinsics/random.c
@@
-358,7
+358,10
@@
init_rand_state (prng_state* rs, const bool locked)
uint64_t os_seed;
getosrandom (&os_seed, sizeof (os_seed));
for (uint64_t i = 0; i < sizeof (master_state) / sizeof (uint64_t); i++)
- master_state[i] = splitmix64 (os_seed);
+ {
+ os_seed = splitmix64 (os_seed);
+ master_state[i] = os_seed;
+ }
njumps = 0;
master_init = true;
}