From: Jens Axboe Date: Tue, 27 Feb 2007 18:56:43 +0000 (+0100) Subject: Temporary iodepth_low work-around for syslets X-Git-Tag: fio-1.12~1 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=9467b77c9ac41f09a93a8a984d21b94c1f7d515e;hp=a0a930efb970a688c0e21e396755210e1bdd05a9 Temporary iodepth_low work-around for syslets syslet really wants iodepth_low=1 for sequential workloads, otherwise when fio starts issuing a new sequence of io, we'll have pending-and-unsubmitted requests from the previous process. The results is seeky instead of sequential requests. Signed-off-by: Jens Axboe --- diff --git a/init.c b/init.c index 636e9576..33a1c281 100644 --- a/init.c +++ b/init.c @@ -708,8 +708,17 @@ static void fixup_options(struct thread_data *td) /* * The low water mark cannot be bigger than the iodepth */ - if (td->iodepth_low > td->iodepth || !td->iodepth_low) - td->iodepth_low = td->iodepth; + if (td->iodepth_low > td->iodepth || !td->iodepth_low) { + /* + * syslet work around - if the workload is sequential, + * we want to let the queue drain all the way down to + * avoid seeking between async threads + */ + if (!strcmp(td->io_ops->name, "syslet-rw") && !td_random(td)) + td->iodepth_low = 1; + else + td->iodepth_low = td->iodepth; + } /* * If batch number isn't set, default to the same as iodepth