From 3ed207174794c60c9030edd367425e99a4c6fe74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20B=2E=20Brandenburg?= Date: Sat, 9 Oct 2010 22:42:53 -0400 Subject: plot: add support for semi-part experiments --- plot.py | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) (limited to 'plot.py') diff --git a/plot.py b/plot.py index 5286b14..c6676e7 100755 --- a/plot.py +++ b/plot.py @@ -504,6 +504,76 @@ class SchedPlotter(defapp.App): else: self.plot(gs, title, xname, conf) + def plot_semipart(self, tmpfile, name, conf): + if 'soft' in conf: + titles = ['P-EDF (load)', 'P-EDF (idle)'] + else: + titles = ['C-EDF (load)', 'C-EDF (idle)'] + + titles += [ + 'EDF-WM (load)', + 'EDF-WM (idle)', + 'NPS-F (load, delta=1)', + 'NPS-F (load, delta=4)', + 'NPS-F (idle, delta=1)', + 'NPS-F (idle, delta=4)', + 'C-NPS-F (load, delta=1)', + 'C-NPS-F (load, delta=4)', + 'C-NPS-F (idle, delta=1)', + 'C-NPS-F (idle, delta=4)'] + + if 'soft' in conf: + titles += [ + 'EDF-fm (load)', + 'EDF-fm (idle)', + ] + + p = self.make_plot(name) + + p.title = scenario_heading(conf, True) + + if 'sched' in conf: + p.curves += [curve(fname=tmpfile, xcol=2, ycol=(y + 3), title=t) + for (y, t) in enumerate(titles)] + p.ylabel = "ratio of schedulable task sets" + p.xlabel = "task set utilization cap (prior to overhead accounting)" + p.xticks = (0, 1) + p.xrange = (0.95, 24.05) + p.title += "; %skB WSS" % conf['key'] + elif 'wsched' in conf: + p.curves += [curve(fname=tmpfile, xcol=1, ycol=(y + 3), title=t) + for (y, t) in enumerate(titles)] + p.xlabel = "working set size (WSS)" + p.ylabel = "weighted schedulability" + p.xticks = (0, 64) + else: + self.err("What kind of semipart experiment is this?") + + + #### Styling. + + if not self.setup_png(p): + p.rounded_caps = True + p.font = 'Helvetica' + + p.font_size = '10' + p.size = ('20cm', '10cm') + p.monochrome = False + p.dashed_lines = True + p.key = 'below' + p.default_style = 'lines lw 6' + + if self.options.smooth: + p.default_style += " smooth bezier" + + p.ylabel += (' [soft]' if 'soft' in conf else ' [hard]') + + if self.options.save_script: + p.gnuplot_save(p.output + '.plot') + else: + p.gnuplot_exec() + + def plot_file(self, datafile): bname = basename(datafile) name, ext = splitext(bname) @@ -528,6 +598,7 @@ class SchedPlotter(defapp.App): 'rtss08' : self.plot_rtss08, 'rtss09' : self.plot_rtss09_split if self.options.split else self.plot_rtss09, 'ospert10' : self.plot_ospert10, + 'rtas11' : self.plot_semipart, } if self.options.experiment: -- cgit v1.2.2