- if (td->bw_avg_time < bw_avg_time)
- bw_avg_time = td->bw_avg_time;
- if (td->runstate == TD_RUNNING || td->runstate == TD_VERIFYING||
- td->runstate == TD_FSYNCING) {
- nr_running++;
- t_rate += td->rate;
- m_rate += td->ratemin;
- } else if (td->runstate < TD_RUNNING)
- nr_pending++;
-
- if (elapsed >= 3)
- eta_secs[i] = thread_eta(td, elapsed);
+ if (is_power_of_2(td->o.kb_base))
+ je->is_pow2 = 1;
+ if (td->o.bw_avg_time < bw_avg_time)
+ bw_avg_time = td->o.bw_avg_time;
+ if (td->runstate == TD_RUNNING || td->runstate == TD_VERIFYING
+ || td->runstate == TD_FSYNCING
+ || td->runstate == TD_PRE_READING) {
+ je->nr_running++;
+ if (td_read(td)) {
+ je->t_rate += td->o.rate[DDIR_READ];
+ je->t_iops += td->o.rate_iops[DDIR_READ];
+ je->m_rate += td->o.ratemin[DDIR_READ];
+ je->m_iops += td->o.rate_iops_min[DDIR_READ];
+ }
+ if (td_write(td)) {
+ je->t_rate += td->o.rate[DDIR_WRITE];
+ je->t_iops += td->o.rate_iops[DDIR_WRITE];
+ je->m_rate += td->o.ratemin[DDIR_WRITE];
+ je->m_iops += td->o.rate_iops_min[DDIR_WRITE];
+ }
+ if (td_trim(td)) {
+ je->t_rate += td->o.rate[DDIR_TRIM];
+ je->t_iops += td->o.rate_iops[DDIR_TRIM];
+ je->m_rate += td->o.ratemin[DDIR_TRIM];
+ je->m_iops += td->o.rate_iops_min[DDIR_TRIM];
+ }
+
+ je->files_open += td->nr_open_files;
+ } else if (td->runstate == TD_RAMP) {
+ je->nr_running++;
+ je->nr_ramp++;
+ } else if (td->runstate == TD_SETTING_UP)
+ je->nr_running++;
+ else if (td->runstate < TD_RUNNING)
+ je->nr_pending++;
+
+ if (je->elapsed_sec >= 3)
+ eta_secs[i] = thread_eta(td);