Recent changes (master)
The following changes since commit 40e8d8314f10a578765e20a4eb574b2603d292df:
Merge branch 'fio-histo-log-pctiles' of https://github.com/parallel-fs-utils/fio (2018-07-25 14:42:57 -0600)
are available in the git repository at:
git://git.kernel.dk/fio.git master
for you to fetch changes up to a871240086ca6bdc52f79d7459ed283c5a359299:
Merge branch 'sgunmap2' of https://github.com/vincentkfu/fio (2018-07-26 11:47:28 -0600)
----------------------------------------------------------------
Jens Axboe (1):
Merge branch 'sgunmap2' of https://github.com/vincentkfu/fio
Vincent Fu (7):
ioengines: have ioengines with commit do own io accounting for trims
stat: add IO submit and complete depths to JSON output engines/sg: support trim operations via the UNMAP command engines/sg: add cmdp and dxferp for trims to sg error string engines/sg: move asserts and debug statements behind a debug flag
testing: add test scripts for sg ioengine
docs: update HOWTO and manpage for sg trim support
HOWTO | 9 +- engines/libaio.c | 2 + engines/sg.c | 421 ++++++++++++++++++++++++++++++++++++++++++++++-------- fio.1 | 7 +- ioengines.c | 2 +- stat.c | 45 +++++- t/sgunmap-perf.py | 115 +++++++++++++++ t/sgunmap-test.py | 173 ++++++++++++++++++++++ 8 files changed, 701 insertions(+), 73 deletions(-) create mode 100755 t/sgunmap-perf.py create mode 100755 t/sgunmap-test.py
---
Diff of recent changes:
HOWTO +6 -3
@@ -991,13 +991,15 @@ I/O type **write** Sequential writes. **trim** - Sequential trims (Linux block devices only). + Sequential trims (Linux block devices and SCSI + character devices only). **randread** Random reads. **randwrite** Random writes. **randtrim** - Random trims (Linux block devices only). + Random trims (Linux block devices and SCSI + character devices only). **rw,readwrite** Sequential mixed reads and writes. **randrw**
@@ -1748,7 +1750,7 @@ I/O engine ioctl, or if the target is an sg character device we use :manpage:`read(2)` and :manpage:`write(2)` for asynchronous I/O. Requires :option:`filename` option to specify either block or - character devices. + character devices. This engine supports trim operations. The sg engine includes engine specific options. **null**
@@ -2082,6 +2084,7 @@ with the caveat that when used on the command line, they must come after the the force unit access (fua) flag. Default is 0. .. option:: sg_write_mode=str : [sg] + Specify the type of write commands to issue. This option can take three values: **write**
engines/libaio.c +2 -0
@@ -207,6 +207,8 @@ static enum fio_q_status fio_libaio_queue(struct thread_data *td,return FIO_Q_BUSY ;do_io_u_trim (td, io_u); +io_u_mark_submit (td,1 ); +io_u_mark_complete (td,1 );return FIO_Q_COMPLETED ; }
engines/sg.c +361 -60
597 lines not on this page · raw message
fio.1 +4 -3
@@ -757,7 +757,7 @@ Sequential reads. Sequential writes. .TP .B trim -Sequential trims (Linux block devices only). +Sequential trims (Linux block devices and SCSI character devices only). .TP .B randread Random reads.
@@ -766,7 +766,7 @@ Random reads. Random writes. .TP .B randtrim -Random trims (Linux block devices only). +Random trims (Linux block devices and SCSI character devices only). .TP .B rw,readwrite Sequential mixed reads and writes.
@@ -1524,7 +1524,8 @@ SCSI generic sg v3 I/O. May either be synchronous using the SG_IO ioctl, or if the target is an sg character device we use \fBread\fR\|(2) and \fBwrite\fR\|(2) for asynchronous I/O. Requires \fBfilename\fR option to specify either block or -character devices. The sg engine includes engine specific options. +character devices. This engine supports trim operations. The +sg engine includes engine specific options. .TP .B null Doesn't transfer any data, just pretends to. This is mainly used to
ioengines.c +1 -1
@@ -350,7 +350,7 @@ enum fio_q_status td_io_queue(struct thread_data *td, struct io_u *io_u) "invalid block size. Try setting direct=0.\n"); } -if (!td->io_ops->commit || io_u->ddir ==DDIR_TRIM ) { +if (!td->io_ops->commit) {io_u_mark_submit (td,1 );io_u_mark_complete (td,1 ); }
stat.c +39 -6
58 lines not on this page · raw message
t/sgunmap-perf.py new file +115 -0
115 lines not on this page · raw message
t/sgunmap-test.py new file +173 -0
173 lines not on this page · raw message