+ fio_gettime(&now, NULL);
+ rate_time = mtime_since(&rate_prev_time, &now);
+
+ if (write_bw_log && rate_time > bw_avg_time && !in_ramp_time(td)) {
+ calc_rate(unified_rw_rep, rate_time, io_bytes, rate_io_bytes,
+ je->rate);
+ memcpy(&rate_prev_time, &now, sizeof(now));
+ add_agg_sample(je->rate[DDIR_READ], DDIR_READ, 0);
+ add_agg_sample(je->rate[DDIR_WRITE], DDIR_WRITE, 0);
+ add_agg_sample(je->rate[DDIR_TRIM], DDIR_TRIM, 0);
+ }
+
+ disp_time = mtime_since(&disp_prev_time, &now);
+
+ /*
+ * Allow a little slack, the target is to print it every 1000 msecs
+ */
+ if (!force && disp_time < 900)
+ return 0;
+
+ calc_rate(unified_rw_rep, disp_time, io_bytes, disp_io_bytes, je->rate);
+ calc_iops(unified_rw_rep, disp_time, io_iops, disp_io_iops, je->iops);
+
+ memcpy(&disp_prev_time, &now, sizeof(now));
+
+ if (!force && !je->nr_running && !je->nr_pending)
+ return 0;
+
+ je->nr_threads = thread_number;
+ memcpy(je->run_str, run_str, thread_number * sizeof(char));
+
+ return 1;
+}
+
+void display_thread_status(struct jobs_eta *je)
+{
+ static int linelen_last;
+ static int eta_good;
+ char output[REAL_MAX_JOBS + 512], *p = output;
+ char eta_str[128];
+ double perc = 0.0;
+
+ if (je->eta_sec != INT_MAX && je->elapsed_sec) {
+ perc = (double) je->elapsed_sec / (double) (je->elapsed_sec + je->eta_sec);
+ eta_to_str(eta_str, je->eta_sec);