13 #define td_var_offset(var) ((size_t) &((struct thread_options *)0)->var)
16 * Check if mmap/mmaphuge has a :/foo/bar/file at the end. If so, return that.
18 static char *get_opt_postfix(const char *str)
20 char *p = strstr(str, ":");
26 strip_blank_front(&p);
31 static int bs_cmp(const void *p1, const void *p2)
33 const struct bssplit *bsp1 = p1;
34 const struct bssplit *bsp2 = p2;
36 return bsp1->perc < bsp2->perc;
39 static int str_bssplit_cb(void *data, const char *input)
41 struct thread_data *td = data;
42 char *fname, *str, *p;
43 unsigned int i, perc, perc_missing;
44 unsigned int max_bs, min_bs;
47 p = str = strdup(input);
49 strip_blank_front(&str);
53 td->o.bssplit = malloc(4 * sizeof(struct bssplit));
58 while ((fname = strsep(&str, ":")) != NULL) {
65 * grow struct buffer, if needed
67 if (i == td->o.bssplit_nr) {
68 td->o.bssplit_nr <<= 1;
69 td->o.bssplit = realloc(td->o.bssplit, td->o.bssplit_nr * sizeof(struct bssplit));
72 perc_str = strstr(fname, "/");
76 perc = atoi(perc_str);
84 if (str_to_decimal(fname, &val, 1)) {
85 log_err("fio: bssplit conversion failed\n");
95 td->o.bssplit[i].bs = val;
96 td->o.bssplit[i].perc = perc;
100 td->o.bssplit_nr = i;
103 * Now check if the percentages add up, and how much is missing
105 perc = perc_missing = 0;
106 for (i = 0; i < td->o.bssplit_nr; i++) {
107 struct bssplit *bsp = &td->o.bssplit[i];
109 if (bsp->perc == (unsigned char) -1)
116 log_err("fio: bssplit percentages add to more than 100%%\n");
121 * If values didn't have a percentage set, divide the remains between
125 for (i = 0; i < td->o.bssplit_nr; i++) {
126 struct bssplit *bsp = &td->o.bssplit[i];
128 if (bsp->perc == (unsigned char) -1)
129 bsp->perc = (100 - perc) / perc_missing;
133 td->o.min_bs[DDIR_READ] = td->o.min_bs[DDIR_WRITE] = min_bs;
134 td->o.max_bs[DDIR_READ] = td->o.max_bs[DDIR_WRITE] = max_bs;
137 * now sort based on percentages, for ease of lookup
139 qsort(td->o.bssplit, td->o.bssplit_nr, sizeof(struct bssplit), bs_cmp);
145 static int str_rw_cb(void *data, const char *str)
147 struct thread_data *td = data;
148 char *nr = get_opt_postfix(str);
152 td->o.ddir_nr = atoi(nr);
157 static int str_mem_cb(void *data, const char *mem)
159 struct thread_data *td = data;
161 if (td->o.mem_type == MEM_MMAPHUGE || td->o.mem_type == MEM_MMAP) {
162 td->mmapfile = get_opt_postfix(mem);
163 if (td->o.mem_type == MEM_MMAPHUGE && !td->mmapfile) {
164 log_err("fio: mmaphuge:/path/to/file\n");
172 static int str_lockmem_cb(void fio_unused *data, unsigned long *val)
178 #ifdef FIO_HAVE_IOPRIO
179 static int str_prioclass_cb(void *data, unsigned int *val)
181 struct thread_data *td = data;
185 * mask off old class bits, str_prio_cb() may have set a default class
187 mask = (1 << IOPRIO_CLASS_SHIFT) - 1;
190 td->ioprio |= *val << IOPRIO_CLASS_SHIFT;
195 static int str_prio_cb(void *data, unsigned int *val)
197 struct thread_data *td = data;
202 * If no class is set, assume BE
204 if ((td->ioprio >> IOPRIO_CLASS_SHIFT) == 0)
205 td->ioprio |= IOPRIO_CLASS_BE << IOPRIO_CLASS_SHIFT;
212 static int str_exitall_cb(void)
214 exitall_on_terminate = 1;
218 #ifdef FIO_HAVE_CPU_AFFINITY
219 static int str_cpumask_cb(void *data, unsigned int *val)
221 struct thread_data *td = data;
224 CPU_ZERO(&td->o.cpumask);
226 for (i = 0; i < sizeof(int) * 8; i++)
228 CPU_SET(*val, &td->o.cpumask);
230 td->o.cpumask_set = 1;
234 static int str_cpus_allowed_cb(void *data, const char *input)
236 struct thread_data *td = data;
239 CPU_ZERO(&td->o.cpumask);
241 p = str = strdup(input);
243 strip_blank_front(&str);
244 strip_blank_end(str);
246 while ((cpu = strsep(&str, ",")) != NULL) {
249 CPU_SET(atoi(cpu), &td->o.cpumask);
253 td->o.cpumask_set = 1;
259 static int str_fst_cb(void *data, const char *str)
261 struct thread_data *td = data;
262 char *nr = get_opt_postfix(str);
264 td->file_service_nr = 1;
266 td->file_service_nr = atoi(nr);
271 static int str_filename_cb(void *data, const char *input)
273 struct thread_data *td = data;
274 char *fname, *str, *p;
276 p = str = strdup(input);
278 strip_blank_front(&str);
279 strip_blank_end(str);
281 if (!td->files_index)
284 while ((fname = strsep(&str, ":")) != NULL) {
295 static int str_directory_cb(void *data, const char fio_unused *str)
297 struct thread_data *td = data;
300 if (lstat(td->o.directory, &sb) < 0) {
301 log_err("fio: %s is not a directory\n", td->o.directory);
302 td_verror(td, errno, "lstat");
305 if (!S_ISDIR(sb.st_mode)) {
306 log_err("fio: %s is not a directory\n", td->o.directory);
313 static int str_opendir_cb(void *data, const char fio_unused *str)
315 struct thread_data *td = data;
317 if (!td->files_index)
320 return add_dir_files(td, td->o.opendir);
323 static int str_verify_offset_cb(void *data, unsigned int *off)
325 struct thread_data *td = data;
327 if (*off && *off < sizeof(struct verify_header)) {
328 log_err("fio: verify_offset too small\n");
332 td->o.verify_offset = *off;
336 static int str_verify_cb(void *data, const char *mem)
338 struct thread_data *td = data;
339 unsigned int nr, msb;
342 if (td->o.verify != VERIFY_PATTERN)
345 pat = get_opt_postfix(mem);
347 log_err("fio: missing pattern\n");
351 if (strstr(pat, "0x") || strstr(pat, "0X"))
352 nr = strtol(pat, NULL, 16);
354 nr = strtol(pat, NULL, 16);
358 td->o.verify_pattern_bytes = 1;
360 td->o.verify_pattern_bytes = 2;
362 td->o.verify_pattern_bytes = 3;
364 td->o.verify_pattern_bytes = 4;
366 td->o.verify_pattern = nr;
370 #define __stringify_1(x) #x
371 #define __stringify(x) __stringify_1(x)
374 * Map of job/command line options
376 static struct fio_option options[] = {
378 .name = "description",
379 .type = FIO_OPT_STR_STORE,
380 .off1 = td_var_offset(description),
381 .help = "Text job description",
385 .type = FIO_OPT_STR_STORE,
386 .off1 = td_var_offset(name),
387 .help = "Name of this job",
391 .type = FIO_OPT_STR_STORE,
392 .off1 = td_var_offset(directory),
393 .cb = str_directory_cb,
394 .help = "Directory to store files in",
398 .type = FIO_OPT_STR_STORE,
399 .off1 = td_var_offset(filename),
400 .cb = str_filename_cb,
401 .help = "File(s) to use for the workload",
405 .type = FIO_OPT_STR_STORE,
406 .off1 = td_var_offset(opendir),
407 .cb = str_opendir_cb,
408 .help = "Recursively add files from this directory and down",
412 .alias = "readwrite",
415 .off1 = td_var_offset(td_ddir),
416 .help = "IO direction",
420 .oval = TD_DDIR_READ,
421 .help = "Sequential read",
424 .oval = TD_DDIR_WRITE,
425 .help = "Sequential write",
427 { .ival = "randread",
428 .oval = TD_DDIR_RANDREAD,
429 .help = "Random read",
431 { .ival = "randwrite",
432 .oval = TD_DDIR_RANDWRITE,
433 .help = "Random write",
437 .help = "Sequential read and write mix",
440 .oval = TD_DDIR_RANDRW,
441 .help = "Random read and write mix"
447 .type = FIO_OPT_STR_STORE,
448 .off1 = td_var_offset(ioengine),
449 .help = "IO engine to use",
453 .help = "Use read/write",
456 .help = "Use pread/pwrite",
458 #ifdef FIO_HAVE_LIBAIO
460 .help = "Linux native asynchronous IO",
463 #ifdef FIO_HAVE_POSIXAIO
464 { .ival = "posixaio",
465 .help = "POSIX asynchronous IO",
469 .help = "Memory mapped IO",
471 #ifdef FIO_HAVE_SPLICE
473 .help = "splice/vmsplice based IO",
475 { .ival = "netsplice",
476 .help = "splice/vmsplice to/from the network",
481 .help = "SCSI generic v3 IO",
485 .help = "Testing engine (no data transfer)",
488 .help = "Network IO",
490 #ifdef FIO_HAVE_SYSLET
491 { .ival = "syslet-rw",
492 .help = "syslet enabled async pread/pwrite IO",
496 .help = "CPU cycler burner engine",
498 #ifdef FIO_HAVE_GUASI
500 .help = "GUASI IO engine",
503 { .ival = "external",
504 .help = "Load external engine (append name)",
511 .off1 = td_var_offset(iodepth),
512 .help = "Amount of IO buffers to keep in flight",
517 .name = "iodepth_batch",
519 .off1 = td_var_offset(iodepth_batch),
520 .help = "Number of IO to submit in one go",
524 .name = "iodepth_low",
526 .off1 = td_var_offset(iodepth_low),
527 .help = "Low water mark for queuing depth",
532 .type = FIO_OPT_STR_VAL,
533 .off1 = td_var_offset(size),
535 .help = "Total size of device or files",
538 .name = "fill_device",
539 .type = FIO_OPT_BOOL,
540 .off1 = td_var_offset(fill_device),
541 .help = "Write until an ENOSPC error occurs",
546 .type = FIO_OPT_STR_VAL,
547 .off1 = td_var_offset(file_size_low),
548 .off2 = td_var_offset(file_size_high),
550 .help = "Size of individual files",
554 .alias = "fileoffset",
555 .type = FIO_OPT_STR_VAL,
556 .off1 = td_var_offset(start_offset),
557 .help = "Start IO from this offset",
562 .alias = "blocksize",
563 .type = FIO_OPT_STR_VAL_INT,
564 .off1 = td_var_offset(bs[DDIR_READ]),
565 .off2 = td_var_offset(bs[DDIR_WRITE]),
567 .help = "Block size unit",
573 .alias = "blocksize_range",
574 .type = FIO_OPT_RANGE,
575 .off1 = td_var_offset(min_bs[DDIR_READ]),
576 .off2 = td_var_offset(max_bs[DDIR_READ]),
577 .off3 = td_var_offset(min_bs[DDIR_WRITE]),
578 .off4 = td_var_offset(max_bs[DDIR_WRITE]),
580 .help = "Set block size range (in more detail than bs)",
586 .cb = str_bssplit_cb,
587 .help = "Set a specific mix of block sizes",
591 .name = "bs_unaligned",
592 .alias = "blocksize_unaligned",
593 .type = FIO_OPT_STR_SET,
594 .off1 = td_var_offset(bs_unaligned),
595 .help = "Don't sector align IO buffer sizes",
599 .name = "randrepeat",
600 .type = FIO_OPT_BOOL,
601 .off1 = td_var_offset(rand_repeatable),
602 .help = "Use repeatable random IO pattern",
607 .name = "norandommap",
608 .type = FIO_OPT_STR_SET,
609 .off1 = td_var_offset(norandommap),
610 .help = "Accept potential duplicate random blocks",
616 .off1 = td_var_offset(nr_files),
617 .help = "Split job workload between this number of files",
623 .off1 = td_var_offset(open_files),
624 .help = "Number of files to keep open at the same time",
627 .name = "file_service_type",
630 .off1 = td_var_offset(file_service_type),
631 .help = "How to select which file to service next",
635 .oval = FIO_FSERVICE_RANDOM,
636 .help = "Choose a file at random",
638 { .ival = "roundrobin",
639 .oval = FIO_FSERVICE_RR,
640 .help = "Round robin select files",
646 .name = "fadvise_hint",
647 .type = FIO_OPT_BOOL,
648 .off1 = td_var_offset(fadvise_hint),
649 .help = "Use fadvise() to advise the kernel on IO pattern",
655 .off1 = td_var_offset(fsync_blocks),
656 .help = "Issue fsync for writes every given number of blocks",
661 .type = FIO_OPT_BOOL,
662 .off1 = td_var_offset(odirect),
663 .help = "Use O_DIRECT IO (negates buffered)",
668 .type = FIO_OPT_BOOL,
669 .off1 = td_var_offset(odirect),
671 .help = "Use buffered IO (negates direct)",
676 .type = FIO_OPT_BOOL,
677 .off1 = td_var_offset(overwrite),
678 .help = "When writing, set whether to overwrite current data",
684 .off1 = td_var_offset(loops),
685 .help = "Number of times to run the job",
691 .off1 = td_var_offset(numjobs),
692 .help = "Duplicate this job this many times",
696 .name = "startdelay",
698 .off1 = td_var_offset(start_delay),
699 .help = "Only start job when this period has passed",
705 .type = FIO_OPT_STR_VAL_TIME,
706 .off1 = td_var_offset(timeout),
707 .help = "Stop workload when this amount of time has passed",
711 .name = "time_based",
712 .type = FIO_OPT_STR_SET,
713 .off1 = td_var_offset(time_based),
714 .help = "Keep running until runtime/timeout is met",
721 .off1 = td_var_offset(mem_type),
722 .help = "Backing type for IO buffers",
727 .help = "Use malloc(3) for IO buffers",
731 .help = "Use shared memory segments for IO buffers",
733 #ifdef FIO_HAVE_HUGETLB
736 .help = "Like shm, but use huge pages",
741 .help = "Use mmap(2) (file or anon) for IO buffers",
743 #ifdef FIO_HAVE_HUGETLB
744 { .ival = "mmaphuge",
745 .oval = MEM_MMAPHUGE,
746 .help = "Like mmap, but use huge pages",
754 .off1 = td_var_offset(verify),
756 .help = "Verify data written",
761 .help = "Don't do IO verification",
765 .help = "Use md5 checksums for verification",
768 .oval = VERIFY_CRC64,
769 .help = "Use crc64 checksums for verification",
772 .oval = VERIFY_CRC32,
773 .help = "Use crc32 checksums for verification",
776 .oval = VERIFY_CRC16,
777 .help = "Use crc16 checksums for verification",
781 .help = "Use crc7 checksums for verification",
784 .oval = VERIFY_SHA256,
785 .help = "Use sha256 checksums for verification",
788 .oval = VERIFY_SHA512,
789 .help = "Use sha512 checksums for verification",
793 .help = "Use io information",
796 .oval = VERIFY_PATTERN,
797 .help = "Verify a specific buffer pattern",
802 .help = "Pretend to verify",
808 .type = FIO_OPT_BOOL,
809 .off1 = td_var_offset(do_verify),
810 .help = "Run verification stage after write",
815 .name = "verifysort",
816 .type = FIO_OPT_BOOL,
817 .off1 = td_var_offset(verifysort),
818 .help = "Sort written verify blocks for read back",
823 .name = "verify_interval",
824 .type = FIO_OPT_STR_VAL_INT,
825 .off1 = td_var_offset(verify_interval),
826 .minval = 2 * sizeof(struct verify_header),
827 .help = "Store verify buffer header every N bytes",
831 .name = "verify_offset",
832 .type = FIO_OPT_STR_VAL_INT,
833 .help = "Offset verify header location by N bytes",
835 .cb = str_verify_offset_cb,
839 .name = "verify_fatal",
840 .type = FIO_OPT_BOOL,
841 .off1 = td_var_offset(verify_fatal),
843 .help = "Exit on a single verify failure, don't continue",
847 .name = "write_iolog",
848 .type = FIO_OPT_STR_STORE,
849 .off1 = td_var_offset(write_iolog_file),
850 .help = "Store IO pattern to file",
853 .name = "read_iolog",
854 .type = FIO_OPT_STR_STORE,
855 .off1 = td_var_offset(read_iolog_file),
856 .help = "Playback IO pattern from file",
859 .name = "exec_prerun",
860 .type = FIO_OPT_STR_STORE,
861 .off1 = td_var_offset(exec_prerun),
862 .help = "Execute this file prior to running job",
865 .name = "exec_postrun",
866 .type = FIO_OPT_STR_STORE,
867 .off1 = td_var_offset(exec_postrun),
868 .help = "Execute this file after running job",
870 #ifdef FIO_HAVE_IOSCHED_SWITCH
872 .name = "ioscheduler",
873 .type = FIO_OPT_STR_STORE,
874 .off1 = td_var_offset(ioscheduler),
875 .help = "Use this IO scheduler on the backing device",
880 .type = FIO_OPT_STR_VAL,
881 .off1 = td_var_offset(zone_size),
882 .help = "Give size of an IO zone",
887 .type = FIO_OPT_STR_VAL,
888 .off1 = td_var_offset(zone_skip),
889 .help = "Space between IO zones",
894 .type = FIO_OPT_STR_VAL,
895 .cb = str_lockmem_cb,
896 .help = "Lock down this amount of memory",
902 .off1 = td_var_offset(rwmix[DDIR_READ]),
904 .help = "Percentage of mixed workload that is reads",
908 .name = "rwmixwrite",
910 .off1 = td_var_offset(rwmix[DDIR_WRITE]),
912 .help = "Percentage of mixed workload that is writes",
916 .name = "rwmixcycle",
918 .off1 = td_var_offset(rwmixcycle),
919 .help = "Cycle period for mixed read/write workloads (msec)",
921 .parent = "rwmixread",
926 .off1 = td_var_offset(nice),
927 .help = "Set job CPU nice value",
932 #ifdef FIO_HAVE_IOPRIO
937 .help = "Set job IO priority value",
944 .cb = str_prioclass_cb,
945 .help = "Set job IO priority class",
953 .off1 = td_var_offset(thinktime),
954 .help = "Idle time between IO buffers (usec)",
958 .name = "thinktime_spin",
960 .off1 = td_var_offset(thinktime_spin),
961 .help = "Start think time by spinning this amount (usec)",
963 .parent = "thinktime",
966 .name = "thinktime_blocks",
968 .off1 = td_var_offset(thinktime_blocks),
969 .help = "IO buffer period between 'thinktime'",
971 .parent = "thinktime",
976 .off1 = td_var_offset(rate),
977 .help = "Set bandwidth rate",
982 .off1 = td_var_offset(ratemin),
983 .help = "Job must meet this rate or it will be shutdown",
989 .off1 = td_var_offset(rate_iops),
990 .help = "Limit IO used to this number of IO operations/sec",
993 .name = "rate_iops_min",
995 .off1 = td_var_offset(rate_iops_min),
996 .help = "Job must meet this rate or it will be shutdown",
997 .parent = "rate_iops",
1000 .name = "ratecycle",
1001 .type = FIO_OPT_INT,
1002 .off1 = td_var_offset(ratecycle),
1003 .help = "Window average for rate limits (msec)",
1008 .name = "invalidate",
1009 .type = FIO_OPT_BOOL,
1010 .off1 = td_var_offset(invalidate_cache),
1011 .help = "Invalidate buffer/page cache prior to running job",
1016 .type = FIO_OPT_BOOL,
1017 .off1 = td_var_offset(sync_io),
1018 .help = "Use O_SYNC for buffered writes",
1020 .parent = "buffered",
1023 .name = "bwavgtime",
1024 .type = FIO_OPT_INT,
1025 .off1 = td_var_offset(bw_avg_time),
1026 .help = "Time window over which to calculate bandwidth (msec)",
1030 .name = "create_serialize",
1031 .type = FIO_OPT_BOOL,
1032 .off1 = td_var_offset(create_serialize),
1033 .help = "Serialize creating of job files",
1037 .name = "create_fsync",
1038 .type = FIO_OPT_BOOL,
1039 .off1 = td_var_offset(create_fsync),
1040 .help = "Fsync file after creation",
1045 .type = FIO_OPT_INT,
1046 .off1 = td_var_offset(cpuload),
1047 .help = "Use this percentage of CPU",
1050 .name = "cpuchunks",
1051 .type = FIO_OPT_INT,
1052 .off1 = td_var_offset(cpucycle),
1053 .help = "Length of the CPU burn cycles (usecs)",
1055 .parent = "cpuload",
1057 #ifdef FIO_HAVE_CPU_AFFINITY
1060 .type = FIO_OPT_INT,
1061 .cb = str_cpumask_cb,
1062 .help = "CPU affinity mask",
1065 .name = "cpus_allowed",
1066 .type = FIO_OPT_STR,
1067 .cb = str_cpus_allowed_cb,
1068 .help = "Set CPUs allowed",
1072 .name = "end_fsync",
1073 .type = FIO_OPT_BOOL,
1074 .off1 = td_var_offset(end_fsync),
1075 .help = "Include fsync at the end of job",
1079 .name = "fsync_on_close",
1080 .type = FIO_OPT_BOOL,
1081 .off1 = td_var_offset(fsync_on_close),
1082 .help = "fsync files on close",
1087 .type = FIO_OPT_BOOL,
1088 .off1 = td_var_offset(unlink),
1089 .help = "Unlink created files after job has completed",
1094 .type = FIO_OPT_STR_SET,
1095 .cb = str_exitall_cb,
1096 .help = "Terminate all jobs when one exits",
1099 .name = "stonewall",
1100 .type = FIO_OPT_STR_SET,
1101 .off1 = td_var_offset(stonewall),
1102 .help = "Insert a hard barrier between this job and previous",
1105 .name = "new_group",
1106 .type = FIO_OPT_STR_SET,
1107 .off1 = td_var_offset(new_group),
1108 .help = "Mark the start of a new group (for reporting)",
1112 .type = FIO_OPT_STR_SET,
1113 .off1 = td_var_offset(use_thread),
1114 .help = "Use threads instead of forks",
1117 .name = "write_bw_log",
1118 .type = FIO_OPT_STR_SET,
1119 .off1 = td_var_offset(write_bw_log),
1120 .help = "Write log of bandwidth during run",
1123 .name = "write_lat_log",
1124 .type = FIO_OPT_STR_SET,
1125 .off1 = td_var_offset(write_lat_log),
1126 .help = "Write log of latency during run",
1129 .name = "hugepage-size",
1130 .type = FIO_OPT_STR_VAL,
1131 .off1 = td_var_offset(hugepage_size),
1132 .help = "When using hugepages, specify size of each page",
1133 .def = __stringify(FIO_HUGE_PAGE),
1136 .name = "group_reporting",
1137 .type = FIO_OPT_STR_SET,
1138 .off1 = td_var_offset(group_reporting),
1139 .help = "Do reporting on a per-group basis",
1142 .name = "zero_buffers",
1143 .type = FIO_OPT_STR_SET,
1144 .off1 = td_var_offset(zero_buffers),
1145 .help = "Init IO buffers to all zeroes",
1147 #ifdef FIO_HAVE_DISK_UTIL
1149 .name = "disk_util",
1150 .type = FIO_OPT_BOOL,
1151 .off1 = td_var_offset(do_disk_util),
1152 .help = "Log disk utilization stats",
1161 void fio_options_dup_and_init(struct option *long_options)
1163 struct fio_option *o;
1166 options_init(options);
1169 while (long_options[i].name)
1174 long_options[i].name = o->name;
1175 long_options[i].val = FIO_GETOPT_JOB;
1176 if (o->type == FIO_OPT_STR_SET)
1177 long_options[i].has_arg = no_argument;
1179 long_options[i].has_arg = required_argument;
1183 assert(i < FIO_NR_OPTIONS);
1187 int fio_option_parse(struct thread_data *td, const char *opt)
1189 return parse_option(opt, options, td);
1192 int fio_cmd_option_parse(struct thread_data *td, const char *opt, char *val)
1194 return parse_cmd_option(opt, val, options, td);
1197 void fio_fill_default_options(struct thread_data *td)
1199 fill_default_options(td, options);
1202 int fio_show_option_help(const char *opt)
1204 return show_cmd_help(options, opt);
1207 static void __options_mem(struct thread_data *td, int alloc)
1209 struct thread_options *o = &td->o;
1210 struct fio_option *opt;
1214 for (i = 0, opt = &options[0]; opt->name; i++, opt = &options[i]) {
1215 if (opt->type != FIO_OPT_STR_STORE)
1218 ptr = (void *) o + opt->off1;
1221 *ptr = strdup(*ptr);
1231 * dupe FIO_OPT_STR_STORE options
1233 void options_mem_dupe(struct thread_data *td)
1235 __options_mem(td, 1);
1238 void options_mem_free(struct thread_data fio_unused *td)
1241 __options_mem(td, 0);