From: Erwan Velu Date: Mon, 22 Jul 2013 10:59:04 +0000 (+0200) Subject: fio2gnuplot: Don't plot fake data X-Git-Tag: fio-2.1.2~29 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=d7e30e61f2c1d9c6101cc6896009750aae2e2bcf fio2gnuplot: Don't plot fake data As we did add some fake data to keep as long a possible the coherency between all the fio files, let's ignore them when rendering. As a consequence, we are keeping the time associated to each performance we store instead of a single time for all performance traces. This will increase precision while plotting. --- diff --git a/tools/plot/fio2gnuplot.py b/tools/plot/fio2gnuplot.py index 6bde99ec..03ef0dda 100755 --- a/tools/plot/fio2gnuplot.py +++ b/tools/plot/fio2gnuplot.py @@ -126,14 +126,17 @@ def compute_temp_file(fio_data_file,disk_perf): # We ignore the first 500msec as it doesn't seems to be part of the real benchmark # Time < 500 usually reports BW=0 breaking the min computing - if ((int(time)) > 500): + if (((int(time)) > 500) or (int(time)==-1)): disk_perf[index].append(int(perf)) - perfs.append(perf) + perfs.append("%s %s"% (time, perf)) index = index + 1 # If we reach this point, it means that all the traces are coherent for p in enumerate(perfs): - temp_outfile[p[0]].write("%s %.2f %s\n" % (p[0], float(float(time)/1000), p[1])) + perf_time,perf = p[1].split() + if (perf_time != "-1"): + temp_outfile[p[0]].write("%s %.2f %s\n" % (p[0], float(float(perf_time)/1000), perf)) + for file in files: file.close()