projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
client: add hashes for fd/name lookups
[fio.git]
/
options.c
diff --git
a/options.c
b/options.c
index 06ac6596292851ed0f95a4df8d096a513076026b..f07cc7c42aedcee338fb5e9a7b7a7bbf773f4998 100644
(file)
--- a/
options.c
+++ b/
options.c
@@
-102,7
+102,7
@@
static int bssplit_ddir(struct thread_data *td, int ddir, char *str)
} else
perc = -1;
} else
perc = -1;
- if (str_to_decimal(fname, &val, 1,
1,
td)) {
+ if (str_to_decimal(fname, &val, 1, td)) {
log_err("fio: bssplit conversion failed\n");
free(td->o.bssplit);
return 1;
log_err("fio: bssplit conversion failed\n");
free(td->o.bssplit);
return 1;
@@
-213,7
+213,7
@@
static int str_rw_cb(void *data, const char *str)
else {
long long val;
else {
long long val;
- if (str_to_decimal(nr, &val, 1,
0,
td)) {
+ if (str_to_decimal(nr, &val, 1, td)) {
log_err("fio: rw postfix parsing failed\n");
free(nr);
return 1;
log_err("fio: rw postfix parsing failed\n");
free(nr);
return 1;
@@
-749,6
+749,17
@@
static int str_write_lat_log_cb(void *data, const char *str)
return 0;
}
return 0;
}
+static int str_write_iops_log_cb(void *data, const char *str)
+{
+ struct thread_data *td = data;
+
+ if (str)
+ td->o.iops_log_file = strdup(str);
+
+ td->o.write_iops_log = 1;
+ return 0;
+}
+
static int str_gtod_reduce_cb(void *data, int *il)
{
struct thread_data *td = data;
static int str_gtod_reduce_cb(void *data, int *il)
{
struct thread_data *td = data;
@@
-829,9
+840,6
@@
static int kb_base_verify(struct fio_option *o, void *data)
return 0;
}
return 0;
}
-#define __stringify_1(x) #x
-#define __stringify(x) __stringify_1(x)
-
/*
* Map of job/command line options
*/
/*
* Map of job/command line options
*/
@@
-1824,6
+1832,15
@@
static struct fio_option options[FIO_MAX_OPTS] = {
.help = "Time window over which to calculate bandwidth"
" (msec)",
.def = "500",
.help = "Time window over which to calculate bandwidth"
" (msec)",
.def = "500",
+ .parent = "write_bw_log",
+ },
+ {
+ .name = "iopsavgtime",
+ .type = FIO_OPT_INT,
+ .off1 = td_var_offset(iops_avg_time),
+ .help = "Time window over which to calculate IOPS (msec)",
+ .def = "500",
+ .parent = "write_iops_log",
},
{
.name = "create_serialize",
},
{
.name = "create_serialize",
@@
-1941,12
+1958,19
@@
static struct fio_option options[FIO_MAX_OPTS] = {
.cb = str_write_lat_log_cb,
.help = "Write log of latency during run",
},
.cb = str_write_lat_log_cb,
.help = "Write log of latency during run",
},
+ {
+ .name = "write_iops_log",
+ .type = FIO_OPT_STR,
+ .off1 = td_var_offset(write_iops_log),
+ .cb = str_write_iops_log_cb,
+ .help = "Write log of IOPS during run",
+ },
{
.name = "hugepage-size",
.type = FIO_OPT_INT,
.off1 = td_var_offset(hugepage_size),
.help = "When using hugepages, specify size of each page",
{
.name = "hugepage-size",
.type = FIO_OPT_INT,
.off1 = td_var_offset(hugepage_size),
.help = "When using hugepages, specify size of each page",
- .def = __stringify(FIO_HUGE_PAGE),
+ .def = __
fio_
stringify(FIO_HUGE_PAGE),
},
{
.name = "group_reporting",
},
{
.name = "group_reporting",
@@
-1966,6
+1990,13
@@
static struct fio_option options[FIO_MAX_OPTS] = {
.off1 = td_var_offset(refill_buffers),
.help = "Refill IO buffers on every IO submit",
},
.off1 = td_var_offset(refill_buffers),
.help = "Refill IO buffers on every IO submit",
},
+ {
+ .name = "scramble_buffers",
+ .type = FIO_OPT_BOOL,
+ .off1 = td_var_offset(scramble_buffers),
+ .help = "Slightly scramble buffers on every IO submit",
+ .def = "1",
+ },
{
.name = "clat_percentiles",
.type = FIO_OPT_BOOL,
{
.name = "clat_percentiles",
.type = FIO_OPT_BOOL,