diff options
| author | Bjoern B. Brandenburg <bbb@cs.unc.edu> | 2009-05-05 22:50:59 -0400 |
|---|---|---|
| committer | Bjoern B. Brandenburg <bbb@cs.unc.edu> | 2009-05-05 22:50:59 -0400 |
| commit | 16ae103d0a9ef2e9b0f164bdad98e8734f09df5c (patch) | |
| tree | 3eb4dd37da50a2c6b58340a7f8b7f0aeb1e5de29 | |
| parent | 9bd6338e7a0707ed46d301df38851615226e0cca (diff) | |
little helper for plotting overheads for RTSS09
| -rwxr-xr-x | plot_ohead.py | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/plot_ohead.py b/plot_ohead.py new file mode 100755 index 0000000..89afc7d --- /dev/null +++ b/plot_ohead.py | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | #!/usr/bin/env python | ||
| 2 | from gnuplot import gnuplot, FORMATS | ||
| 3 | |||
| 4 | |||
| 5 | plugins = ['GSN-EDF', 'G-EDF', 'GQ-EDF', 'GHQ-EDF'] | ||
| 6 | master = ['NO_CPU', '3'] | ||
| 7 | events = ['SCHED', 'SCHED2', 'TICK', 'CXS', 'RELEASE', 'SEND_RESCHED'] | ||
| 8 | |||
| 9 | def graph(plugin, master, event, wc): | ||
| 10 | return ['%s.R-%s.%s.csv' % (plugin, master, event), 1, 3 if wc else 2, | ||
| 11 | '%s %s %s %s' % (plugin, event, 'RM' if master != 'NO_CPU' else '', | ||
| 12 | 'WC' if wc else 'AVG')] | ||
| 13 | |||
| 14 | def by_event(wc): | ||
| 15 | for e in events: | ||
| 16 | gs = [] | ||
| 17 | for p in plugins: | ||
| 18 | for m in master: | ||
| 19 | if (p != 'GHQ-EDF' or m == 'NO_CPU') and \ | ||
| 20 | (p != 'GQ-EDF' or e != 'SEND_RESCHED'): | ||
| 21 | gs += [graph(p, m, e, wc)] | ||
| 22 | gnuplot(gs, title='%s %s' % (e, 'WC' if wc else 'AVG')) | ||
| 23 | |||
| 24 | by_event(True) | ||
| 25 | by_event(False) | ||
