.. option:: sg_write_mode=str : [sg]
- Specify the type of write commands to issue. This option can take three values:
+ Specify the type of write commands to issue. This option can take ten values:
**write**
This is the default where write opcodes are issued as usual.
uint64_t *m_rate)
{
unsigned int cputhreads, realthreads, pending;
- int status, ret;
+ int ret;
/*
* reap exited threads (TD_EXITED -> TD_REAPED)
*/
realthreads = pending = cputhreads = 0;
for_each_td(td) {
- int flags = 0;
+ int flags = 0, status;
if (!strcmp(td->o.ioengine, "cpuio"))
cputhreads++;
perc = td->o.rwmix[DDIR_WRITE];
bytes_total += (bytes_total * perc) / 100;
- } else
+ } else {
bytes_total <<= 1;
+ }
}
if (td->runstate == TD_RUNNING || td->runstate == TD_VERIFYING) {
perc = (double) bytes_done / (double) bytes_total;
if (perc > 1.0)
perc = 1.0;
- } else
+ } else {
perc = 0.0;
+ }
if (td->o.time_based) {
if (timeout) {
* Print status of the jobs we know about. This includes rate estimates,
* ETA, thread state, etc.
*/
-bool calc_thread_status(struct jobs_eta *je, int force)
+static bool calc_thread_status(struct jobs_eta *je, int force)
{
int unified_rw_rep;
bool any_td_in_ramp;
io_u->buflen);
} else if ((td->flags & TD_F_SCRAMBLE_BUFFERS) &&
!(td->flags & TD_F_COMPRESS) &&
- !(td->flags & TD_F_DO_VERIFY))
+ !(td->flags & TD_F_DO_VERIFY)) {
do_scramble = 1;
+ }
} else if (io_u->ddir == DDIR_READ) {
/*
* Reset the buf_filled parameters so next time if the
*/
struct value_pair {
const char *ival; /* string option */
- unsigned long long oval;/* output value */
+ unsigned long long oval; /* output value */
const char *help; /* help text for sub option */
int orval; /* OR value */
void *cb; /* sub-option callback */
extern struct json_object * show_thread_status(struct thread_stat *ts, struct group_run_stats *rs, struct flist_head *, struct buf_output *);
extern void show_group_stats(struct group_run_stats *rs, struct buf_output *);
-extern bool calc_thread_status(struct jobs_eta *je, int force);
extern void display_thread_status(struct jobs_eta *je);
extern void __show_run_stats(void);
extern int __show_running_run_stats(void);