The librpma_apm_client, librpma_gpspm_client, and rdma ioengines have
commit functions that record submission latency. In order to avoid
setting issue_time twice add the FIO_ASYNCIO_SETS_ISSUE_TIME flag. Also
add code to update the iolog issue time when needed.
I don't have the means to test this patch.
Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
Link: https://lore.kernel.org/r/20220614155822.307771-6-vincent.fu@samsung.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
.errdetails = librpma_fio_client_errdetails,
.close_file = librpma_fio_file_nop,
.cleanup = client_cleanup,
.errdetails = librpma_fio_client_errdetails,
.close_file = librpma_fio_file_nop,
.cleanup = client_cleanup,
- .flags = FIO_DISKLESSIO,
+ .flags = FIO_DISKLESSIO | FIO_ASYNCIO_SETS_ISSUE_TIME,
.options = librpma_fio_options,
.option_struct_size = sizeof(struct librpma_fio_options_values),
};
.options = librpma_fio_options,
.option_struct_size = sizeof(struct librpma_fio_options_values),
};
- if ((fill_time = fio_fill_issue_time(td)))
+ if ((fill_time = fio_fill_issue_time(td))) {
+ /*
+ * only used for iolog
+ */
+ if (td->o.read_iolog_file)
+ memcpy(&td->last_issue, &now, sizeof(now));
+
+ }
/* move executed io_us from queued[] to flight[] */
for (i = 0; i < ccd->io_u_queued_nr; i++) {
struct io_u *io_u = ccd->io_us_queued[i];
/* move executed io_us from queued[] to flight[] */
for (i = 0; i < ccd->io_u_queued_nr; i++) {
struct io_u *io_u = ccd->io_us_queued[i];
.errdetails = librpma_fio_client_errdetails,
.close_file = librpma_fio_file_nop,
.cleanup = client_cleanup,
.errdetails = librpma_fio_client_errdetails,
.close_file = librpma_fio_file_nop,
.cleanup = client_cleanup,
- .flags = FIO_DISKLESSIO,
+ .flags = FIO_DISKLESSIO | FIO_ASYNCIO_SETS_ISSUE_TIME,
.options = librpma_fio_options,
.option_struct_size = sizeof(struct librpma_fio_options_values),
};
.options = librpma_fio_options,
.option_struct_size = sizeof(struct librpma_fio_options_values),
};
memcpy(&io_u->issue_time, &now, sizeof(now));
io_u_queued(td, io_u);
}
memcpy(&io_u->issue_time, &now, sizeof(now));
io_u_queued(td, io_u);
}
+
+ /*
+ * only used for iolog
+ */
+ if (td->o.read_iolog_file)
+ memcpy(&td->last_issue, &now, sizeof(now));
}
static int fio_rdmaio_commit(struct thread_data *td)
}
static int fio_rdmaio_commit(struct thread_data *td)
.cleanup = fio_rdmaio_cleanup,
.open_file = fio_rdmaio_open_file,
.close_file = fio_rdmaio_close_file,
.cleanup = fio_rdmaio_cleanup,
.open_file = fio_rdmaio_open_file,
.close_file = fio_rdmaio_close_file,
- .flags = FIO_DISKLESSIO | FIO_UNIDIR | FIO_PIPEIO,
+ .flags = FIO_DISKLESSIO | FIO_UNIDIR | FIO_PIPEIO |
+ FIO_ASYNCIO_SETS_ISSUE_TIME,
.options = options,
.option_struct_size = sizeof(struct rdmaio_options),
};
.options = options,
.option_struct_size = sizeof(struct rdmaio_options),
};