Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(701)

Side by Side Diff: tools/testing/perf_testing/create_graph.py

Issue 9071015: Changing display of perf graphs to make them more readable. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/testing/perf_testing/appengine/app.yaml ('k') | tools/testing/perf_testing/index.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 2
3 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 3 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
4 # for details. All rights reserved. Use of this source code is governed by a 4 # for details. All rights reserved. Use of this source code is governed by a
5 # BSD-style license that can be found in the LICENSE file. 5 # BSD-style license that can be found in the LICENSE file.
6 6
7 import datetime 7 import datetime
8 import math 8 import math
9 try: 9 try:
10 from matplotlib.font_manager import FontProperties 10 from matplotlib.font_manager import FontProperties
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
357 self.platform_type), 'Speed (bigger = better)', 16, 14, 'lower left', 357 self.platform_type), 'Speed (bigger = better)', 16, 14, 'lower left',
358 benchmark + png_filename, self.platform_list, get_versions(), 358 benchmark + png_filename, self.platform_list, get_versions(),
359 [benchmark]) 359 [benchmark])
360 360
361 def plot_avg_perf(self, png_filename): 361 def plot_avg_perf(self, png_filename):
362 """Generate a plot that shows the performance changes of the geomentric mean 362 """Generate a plot that shows the performance changes of the geomentric mean
363 of V8 and frog benchmark performance over svn history.""" 363 of V8 and frog benchmark performance over svn history."""
364 (title, y_axis, size_x, size_y, loc, filename) = \ 364 (title, y_axis, size_x, size_y, loc, filename) = \
365 ('Geometric Mean of benchmark %s performance' % self.platform_type, 365 ('Geometric Mean of benchmark %s performance' % self.platform_type,
366 'Speed (bigger = better)', 16, 5, 'center', 'avg'+png_filename) 366 'Speed (bigger = better)', 16, 5, 'center', 'avg'+png_filename)
367 clear_axis = True
367 for platform in self.platform_list: 368 for platform in self.platform_list:
368 self.syle_and_save_perf_plot(title, y_axis, size_x, size_y, loc, filename, 369 self.syle_and_save_perf_plot(title, y_axis, size_x, size_y, loc, filename,
369 [platform], [V8], [V8_MEAN], True) 370 [platform], [V8], [V8_MEAN], clear_axis)
371 clear_axis = False
370 self.syle_and_save_perf_plot(title, y_axis, size_x, size_y, loc, filename, 372 self.syle_and_save_perf_plot(title, y_axis, size_x, size_y, loc, filename,
371 [platform], [FROG], [FROG_MEAN], False) 373 [platform], [FROG], [FROG_MEAN], clear_axis)
372 self.write_html('table',
373 self.revision_dict[platform][V8],
374 'V8 mean', self.values_dict[platform][V8][V8_MEAN],
375 'Frog mean', self.values_dict[platform][FROG][FROG_MEAN],
376 True)
377 374
378 def plot_results(self, png_filename): 375 def plot_results(self, png_filename):
379 self.plot_all_perf(png_filename) 376 self.plot_all_perf(png_filename)
380 self.plot_avg_perf('2' + png_filename) 377 self.plot_avg_perf('2' + png_filename)
381 378
382 379
383 class CommandLinePerformanceTestRunner(PerformanceTestRunner): 380 class CommandLinePerformanceTestRunner(PerformanceTestRunner):
384 """Run performance tests from the command line.""" 381 """Run performance tests from the command line."""
385 382
386 def __init__(self, result_folder_name): 383 def __init__(self, result_folder_name):
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 if cl: 732 if cl:
736 CommandLinePerformanceTestRunner('cl-results').run() 733 CommandLinePerformanceTestRunner('cl-results').run()
737 if size: 734 if size:
738 CompileTimeAndSizeTestRunner('code-time-size').run() 735 CompileTimeAndSizeTestRunner('code-time-size').run()
739 if language: 736 if language:
740 BrowserCorrectnessTestRunner('language', 'browser-correctness').run() 737 BrowserCorrectnessTestRunner('language', 'browser-correctness').run()
741 if perf: 738 if perf:
742 BrowserPerformanceTestRunner('browser-perf').run() 739 BrowserPerformanceTestRunner('browser-perf').run()
743 740
744 if PERFBOT_MODE: 741 if PERFBOT_MODE:
745 upload_to_app_engine() 742 # TODO(efortuna): Temporarily disabled until you make a safe way to provide
743 # your username/password for the uploading process.
744 #upload_to_app_engine()
745 pass
746 746
747 def main(): 747 def main():
748 global PERFBOT_MODE, VERBOSE 748 global PERFBOT_MODE, VERBOSE
749 (cl, size, language, perf, continuous, perfbot, verbose) = parse_args() 749 (cl, size, language, perf, continuous, perfbot, verbose) = parse_args()
750 PERFBOT_MODE = perfbot 750 PERFBOT_MODE = perfbot
751 VERBOSE = verbose 751 VERBOSE = verbose
752 if continuous: 752 if continuous:
753 while True: 753 while True:
754 if has_new_code(): 754 if has_new_code():
755 run_test_sequence(cl, size, language, perf) 755 run_test_sequence(cl, size, language, perf)
756 else: 756 else:
757 time.sleep(SLEEP_TIME) 757 time.sleep(SLEEP_TIME)
758 else: 758 else:
759 run_test_sequence(cl, size, language, perf) 759 run_test_sequence(cl, size, language, perf)
760 760
761 if __name__ == '__main__': 761 if __name__ == '__main__':
762 main() 762 main()
763 763
OLDNEW
« no previous file with comments | « tools/testing/perf_testing/appengine/app.yaml ('k') | tools/testing/perf_testing/index.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698