aboutsummaryrefslogtreecommitdiffstats
path: root/config/config.example.py
diff options
context:
space:
mode:
authorJonathan Herman <hermanjl@cs.unc.edu>2012-11-26 17:06:27 -0500
committerJonathan Herman <hermanjl@cs.unc.edu>2012-11-26 17:06:27 -0500
commitb43b83beead92ff7cf28a5fe5a2710537268aae1 (patch)
treed9c29b14cd18a9df520f36d7e85eb460c30fa7a9 /config/config.example.py
parentcb8db5d30ee769304c2c2b00f2a7d9bcb3c4098f (diff)
Read locations of binary files from path instead of config.py.
Diffstat (limited to 'config/config.example.py')
-rw-r--r--config/config.example.py58
1 files changed, 0 insertions, 58 deletions
diff --git a/config/config.example.py b/config/config.example.py
deleted file mode 100644
index 9f24097..0000000
--- a/config/config.example.py
+++ /dev/null
@@ -1,58 +0,0 @@
1from __future__ import print_function
2import os
3import sys
4import itertools
5
6'''
7These are paths to repository directories.
8
9'''
10REPOS = {'liblitmus' : '/home/hermanjl/git/liblitmus',
11 'sched_trace' : '/home/hermanjl/git/sched_trace',
12 'ft_tools' : '/home/hermanjl/git/feather-trace-tools',
13 'trace-cmd' : '/home/hermanjl/git/trace-cmd'}
14
15BINS = {'rtspin' : '{}/rtspin'.format(REPOS['liblitmus']),
16 'release' : '{}/release_ts'.format(REPOS['liblitmus']),
17 'ftcat' : '{}/ftcat'.format(REPOS['ft_tools']),
18 'ftsplit' : '{}/ft2csv'.format(REPOS['ft_tools']),
19 'ftsort' : '{}/ftsort'.format(REPOS['ft_tools']),
20 'st_trace' : '{}/st_trace'.format(REPOS['ft_tools']),
21 'trace-cmd' : '{}/trace-cmd'.format(REPOS['trace-cmd']),
22 'st_show' : '{}/st_show'.format(REPOS['sched_trace'])}
23
24DEFAULTS = {'params_file' : 'params.py',
25 'sched_file' : 'sched.py',
26 'exps_file' : 'exps.py',
27 'duration' : 10,
28 'spin' : 'rtspin',
29 'cycles' : 2000}
30
31FILES = {'ft_data' : 'ft.bin',
32 'linux_data' : 'trace.dat',
33 'sched_data' : 'st-{}.bin',
34 'log_data' : 'trace.slog',}
35
36PARAMS = {'sched' : 'scheduler',
37 'dur' : 'duration',
38 'kernel': 'uname',
39 'cycles' : 'cpu-frequency'}
40
41SCHED_EVENTS = range(501, 513)
42BASE_EVENTS = ['SCHED', 'RELEASE', 'SCHED2', 'TICK', 'CXS']
43ALL_EVENTS = ["%s_%s" % (e, t) for (e,t) in
44 itertools.product(BASE_EVENTS, ["START","END"])]
45ALL_EVENTS += ['RELEASE_LATENCY']
46BASE_EVENTS += ['RELEASE_LATENCY']
47
48valid = True
49for repo, loc in REPOS.items():
50 if not os.path.isdir(loc):
51 valid = False
52 print("Cannot access repo '%s' at '%s'" % (repo, loc), file=sys.stderr)
53for prog, loc in BINS.items():
54 if not os.path.isfile(loc):
55 valid = False
56 print("Cannot access program '%s' at '%s'" % (prog, loc), file=sys.stderr)
57if not valid:
58 print("Errors in config file", file=sys.stderr)