return cmp;
}
-unsigned int calc_clat_percentiles(unsigned int *io_u_plat, unsigned long nr,
+unsigned int calc_clat_percentiles(unsigned int *io_u_plat, unsigned long long nr,
fio_fp64_t *plist, unsigned long long **output,
unsigned long long *maxv, unsigned long long *minv)
{
- unsigned long sum = 0;
+ unsigned long long sum = 0;
unsigned int len, i, j = 0;
unsigned int oval_len = 0;
unsigned long long *ovals = NULL;
/*
* Find and display the p-th percentile of clat
*/
-static void show_clat_percentiles(unsigned int *io_u_plat, unsigned long nr,
+static void show_clat_percentiles(unsigned int *io_u_plat, unsigned long long nr,
fio_fp64_t *plist, unsigned int precision,
bool is_clat, struct buf_output *out)
{
struct group_run_stats *rs, int ddir, struct json_object *parent)
{
unsigned long long min, max, minv, maxv;
- unsigned long long bw;
+ unsigned long long bw_bytes, bw;
unsigned long long *ovals = NULL;
double mean, dev, iops;
unsigned int len;
json_object_add_value_object(parent,
ts->unified_rw_rep ? "mixed" : ddirname[ddir], dir_object);
+ bw_bytes = 0;
bw = 0;
iops = 0.0;
if (ts->runtime[ddir]) {
uint64_t runt = ts->runtime[ddir];
- bw = ((1000 * ts->io_bytes[ddir]) / runt) / 1024; /* KiB/s */
+ bw_bytes = ((1000 * ts->io_bytes[ddir]) / runt); /* Bytes/s */
+ bw = bw_bytes / 1024; /* KiB/s */
iops = (1000.0 * (uint64_t) ts->total_io_u[ddir]) / runt;
}
json_object_add_value_int(dir_object, "io_bytes", ts->io_bytes[ddir]);
json_object_add_value_int(dir_object, "io_kbytes", ts->io_bytes[ddir] >> 10);
+ json_object_add_value_int(dir_object, "bw_bytes", bw_bytes);
json_object_add_value_int(dir_object, "bw", bw);
json_object_add_value_float(dir_object, "iops", iops);
json_object_add_value_int(dir_object, "runtime", ts->runtime[ddir]);