[PATCH] Time and seek optimizations
[fio.git] / engines / fio-engine-sync.c
index 5919830edcc6cf0a4fe91e57d20fbabad6e7d4bc..c7ddd4c52956125bd408e4c6f2a0d86f95908041 100644 (file)
@@ -45,6 +45,8 @@ static int fio_syncio_prep(struct thread_data *td, struct io_u *io_u)
 
        if (io_u->ddir == DDIR_SYNC)
                return 0;
+       if (io_u->offset == f->last_completed_pos)
+               return 0;
 
        if (lseek(f->fd, io_u->offset, SEEK_SET) == -1) {
                td_verror(td, errno);