From 8a53287722d90631f08590e40c189fa89726eb72 Mon Sep 17 00:00:00 2001 From: Christopher Kenna Date: Mon, 24 Oct 2011 17:47:13 -0400 Subject: added plots for Jim's PI meeting --- plot_rtas12.py | 47 +++++++++++++++++++++++++++++++++++++---------- 1 file changed, 37 insertions(+), 10 deletions(-) (limited to 'plot_rtas12.py') diff --git a/plot_rtas12.py b/plot_rtas12.py index 5cbcabd..d5e9ed9 100755 --- a/plot_rtas12.py +++ b/plot_rtas12.py @@ -76,28 +76,36 @@ def set_plot_opts(opts, p): if opts.paper: ext = 'pdf' p.size = ('8.5cm', '5.25cm') + line_width = 1.5 + point_size = 0.3 p.font_size = '5pt' else: ext = 'png' p.size = (1024, 768) + line_width = 3.0 + point_size = 1.5 + p.font_size = 'font "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans.ttf" 18' p.output = '{0}.{1}'.format(p.output, ext) p.format = ext for i, c in enumerate(p.curves): c.style = "linespoints ls %d" % (i + 1) - # don't use yellow - p.curves[5].style = "linespoints ls 7" + try: + # don't use yellow if we have this curve + p.curves[5].style = "linespoints ls 7" + except IndexError: + pass p.line_styles = [ - (1, "lw 1.5 ps 0.3"), - (2, "lw 1.5 ps 0.3"), - (3, "lw 1.5 ps 0.3"), - (4, "lw 1.5 ps 0.3"), - (5, 'pt 6 lw 1.5 ps 0.3 lc rgbcolor "#ff910d"'), - (6, "pt 7 lw 1.5 ps 0.3"), - (7, 'lw 1.5 ps 0.3 lc rgbcolor "#000000"'), - (8, "lw 1.5 ps 0.3"), + (1, "lw {0} ps {1}".format(line_width, point_size)), + (2, "lw {0} ps {1}".format(line_width, point_size)), + (3, "lw {0} ps {1}".format(line_width, point_size)), + (4, "lw {0} ps {1}".format(line_width, point_size)), + (5, 'pt 6 lw {0} ps {1} lc rgbcolor "#ff910d"'.format(line_width, point_size)), + (6, "pt 7 lw {0} ps {1}".format(line_width, point_size)), + (7, 'lw {0} ps {1} lc rgbcolor "#000000"'.format(line_width, point_size)), + (8, "lw {0} ps {1}".format(line_width, point_size)), ] @@ -184,6 +192,24 @@ def plot_release(opts, data_dir, ycol, title, fname): p.key = 'top left' p.gnuplot_exec() +def plot_release_jim(opts, data_dir, ycol, title, fname): + """Jim just wanted level-A without any techniques and with all our techniques.""" + p = Plot() + p.output = '{0}/{1}'.format(data_dir, fname) + refs = [] # need to save reference to file handle so it is not deleted + + for sched in ['MC', 'MC-MERGE-REDIR']: + o_type = 'LVLA-RELEASE' + fname = '{0}/scheduler={1}_overhead={2}.csv'.format(data_dir, sched, o_type) + ti = '{0} {1}'.format(get_sched_title(sched), get_overhead_title(o_type)) + p.curves += [curve(fname=fname, xcol=gnuplot_col('n_tasks'), ycol=ycol, title=ti)] + p.xlabel = 'number of tasks' + p.ylabel = 'overhead (microseconds)' + set_plot_opts(opts, p) + p.key = 'top left' + p.title = 'level-A worst-case release overhead' + p.gnuplot_exec() + def plot_sched(opts, data_dir, ycol, title, fname): p = Plot() p.output = '{0}/{1}'.format(data_dir, fname) @@ -212,6 +238,7 @@ def main(): plot_release(opts, data_dir, gnuplot_col('max'), 'worst-case release overhead', 'overhead=RELEASE_type=MAX') plot_sched(opts, data_dir, gnuplot_col('avg'), 'average-case scheduling overhead', 'overhead=SCHED_type=AVG') plot_release(opts, data_dir, gnuplot_col('avg'), 'average-case release overhead', 'overhead=RELEASE_type=AVG') + plot_release_jim(opts, data_dir, gnuplot_col('max'), 'worst-case release overhead', 'overhead=RELEASE_type=MAX_for-jim=1') if __name__ == '__main__': main() -- cgit v1.2.2