projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix rand_seed mismatches in verify phase
[fio.git]
/
backend.c
diff --git
a/backend.c
b/backend.c
index 93e66325f08569ec23fee63eb020065191d30616..bf9d066e012abc8a44a938fcbf319a68a81d6d64 100644
(file)
--- a/
backend.c
+++ b/
backend.c
@@
-697,6
+697,13
@@
static uint64_t do_io(struct thread_data *td)
*/
if (td->o.verify != VERIFY_NONE && io_u->ddir == DDIR_READ &&
((io_u->flags & IO_U_F_VER_LIST) || !td_rw(td))) {
*/
if (td->o.verify != VERIFY_NONE && io_u->ddir == DDIR_READ &&
((io_u->flags & IO_U_F_VER_LIST) || !td_rw(td))) {
+
+ if (!td->o.verify_pattern_bytes) {
+ io_u->rand_seed = __rand(&td->__verify_state);
+ if (sizeof(int) != sizeof(long *))
+ io_u->rand_seed *= __rand(&td->__verify_state);
+ }
+
if (td->o.verify_async)
io_u->end_io = verify_io_u_async;
else
if (td->o.verify_async)
io_u->end_io = verify_io_u_async;
else
@@
-707,6
+714,12
@@
static uint64_t do_io(struct thread_data *td)
else
td_set_runstate(td, TD_RUNNING);
else
td_set_runstate(td, TD_RUNNING);
+ if (td_write(td) && io_u->ddir == DDIR_WRITE &&
+ td->o.do_verify &&
+ td->o.verify != VERIFY_NONE &&
+ !td->o.experimental_verify)
+ log_io_piece(td, io_u);
+
ret = td_io_queue(td, io_u);
switch (ret) {
case FIO_Q_COMPLETED:
ret = td_io_queue(td, io_u);
switch (ret) {
case FIO_Q_COMPLETED: