Skip to content

Commit 709bd70

Browse files
Doug Smythiesrafaeljw
authored andcommitted
tools/power/x86/intel_pstate_tracer: change several graphs to autoscale y-axis
Processors have exceeded some of the fixed y-axis scale maximum values. Change them to autoscale the y-axis. Signed-off-by: Doug Smythies <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent e749e09 commit 709bd70

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

tools/power/x86/intel_pstate_tracer/intel_pstate_tracer.py

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def plot_perf_busy_with_sample(cpu_index):
104104
if os.path.exists(file_name):
105105
output_png = "cpu%03d_perf_busy_vs_samples.png" % cpu_index
106106
g_plot = common_all_gnuplot_settings(output_png)
107-
g_plot('set yrange [0:40]')
107+
# autoscale this one, no set y1 range
108108
g_plot('set y2range [0:200]')
109109
g_plot('set y2tics 0, 10')
110110
g_plot('set title "{} : cpu perf busy vs. sample : CPU {:0>3} : {:%F %H:%M}"'.format(testname, cpu_index, datetime.now()))
@@ -125,7 +125,7 @@ def plot_perf_busy(cpu_index):
125125
if os.path.exists(file_name):
126126
output_png = "cpu%03d_perf_busy.png" % cpu_index
127127
g_plot = common_all_gnuplot_settings(output_png)
128-
g_plot('set yrange [0:40]')
128+
# autoscale this one, no set y1 range
129129
g_plot('set y2range [0:200]')
130130
g_plot('set y2tics 0, 10')
131131
g_plot('set title "{} : perf busy : CPU {:0>3} : {:%F %H:%M}"'.format(testname, cpu_index, datetime.now()))
@@ -144,9 +144,7 @@ def plot_durations(cpu_index):
144144
if os.path.exists(file_name):
145145
output_png = "cpu%03d_durations.png" % cpu_index
146146
g_plot = common_all_gnuplot_settings(output_png)
147-
# Should autoscale be used here? Should seconds be used here?
148-
g_plot('set yrange [0:5000]')
149-
g_plot('set ytics 0, 500')
147+
# autoscale this one, no set y range
150148
g_plot('set title "{} : durations : CPU {:0>3} : {:%F %H:%M}"'.format(testname, cpu_index, datetime.now()))
151149
g_plot('set ylabel "Timer Duration (MilliSeconds)"')
152150
# override common
@@ -176,7 +174,7 @@ def plot_pstate_cpu_with_sample():
176174
if os.path.exists('cpu.csv'):
177175
output_png = 'all_cpu_pstates_vs_samples.png'
178176
g_plot = common_all_gnuplot_settings(output_png)
179-
g_plot('set yrange [0:40]')
177+
# autoscale this one, no set y range
180178
# override common
181179
g_plot('set xlabel "Samples"')
182180
g_plot('set ylabel "P-State"')
@@ -191,7 +189,7 @@ def plot_pstate_cpu():
191189

192190
output_png = 'all_cpu_pstates.png'
193191
g_plot = common_all_gnuplot_settings(output_png)
194-
g_plot('set yrange [0:40]')
192+
# autoscale this one, no set y range
195193
g_plot('set ylabel "P-State"')
196194
g_plot('set title "{} : cpu pstates : {:%F %H:%M}"'.format(testname, datetime.now()))
197195

@@ -222,7 +220,7 @@ def plot_frequency_cpu():
222220

223221
output_png = 'all_cpu_frequencies.png'
224222
g_plot = common_all_gnuplot_settings(output_png)
225-
g_plot('set yrange [0:4]')
223+
# autoscale this one, no set y range
226224
g_plot('set ylabel "CPU Frequency (GHz)"')
227225
g_plot('set title "{} : cpu frequencies : {:%F %H:%M}"'.format(testname, datetime.now()))
228226

@@ -236,7 +234,7 @@ def plot_duration_cpu():
236234

237235
output_png = 'all_cpu_durations.png'
238236
g_plot = common_all_gnuplot_settings(output_png)
239-
g_plot('set yrange [0:5000]')
237+
# autoscale this one, no set y range
240238
g_plot('set ytics 0, 500')
241239
g_plot('set ylabel "Timer Duration (MilliSeconds)"')
242240
g_plot('set title "{} : cpu durations : {:%F %H:%M}"'.format(testname, datetime.now()))

0 commit comments

Comments
 (0)