Submission latency (fio)
Submission latency in fio is the elapsed time from initialization of an I/O unit to an engine-dependent submission boundary.
In fio, slat starts when the I/O unit is initialized. For synchronous engines it ends just before the engine queue function is called. For asynchronous engines it ends when the queue call returns, together with the commit call if the engine defines one. Engines that record their own issue time move that boundary, so the engine and fio version belong with any slat value. [1] [3]
fio reports total latency as slat plus clat. Synchronous engines do not record slat at all, so the slat row and its percentiles are absent for them rather than zero. It is not an application-arrival clock, and its sample count need not be inferred from a different latency field. [1] [5]
Percentiles come from a log-linear histogram with 64 buckets in each of 29 groups, or 1,856 buckets. The bucket layout bounds the relative error at about 1/128 of the value (0.78%), and values up to 2^34 ns, about 17.2 s, are tracked at that precision. [6]
Relations
Advantages
- Separates the time spent before an I/O reaches the engine's submission boundary from the completion time that fio reports as clat. [1]
Limitations
- Histogram percentiles are bucket representatives rather than individual samples, so differences smaller than the bucket width are not resolved. [6]
- No sample is kept when disable_slat is set, when stats are off or during ramp time, so a missing value does not show that submission was free. [4]
Citations
- fio documentation: interpreting slat, clat and lat; engine-dependent timing boundaries.
- fio source, ioengines.c at tag fio-3.43: td_io_queue and issue-time handling
- fio source, io_u.c at tag fio-3.43: io_u_queued and slat sample gating
- fio source, stat.c at tag fio-3.43: add_slat_sample
- fio source, stat.h at tag fio-3.43: latency histogram constants and error bound
Further reading
Sources & caveats
- fio is the fio HOWTO at readthedocs master, read in the slat, clat, lat and slat_percentiles sections. The fio 3.43 HOWTO text is identical there.
- fio-engines, fio-iou, fio-stat and fio-stat-h are fio source files at tag fio-3.43, read in td_io_queue, io_u_queued, add_slat_sample and the histogram constants.
- 64 buckets, 29 groups and 1,856 buckets come from FIO_IO_U_PLAT_BITS and FIO_IO_U_PLAT_GROUP_NR in fio-stat-h.
- 1/128 (0.78%) and 2^34 ns (about 17.2 s) are computed from the error and range formulas in the fio-stat-h comment.