aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fl.fischer@fau.de>2019-08-27 15:15:18 +0200
committerFlorian Fischer <florian.fl.fischer@fau.de>2019-08-27 15:15:18 +0200
commit721e672c897616e53f95b9deca7f8769024c19d5 (patch)
tree7dba6882295795729aa1dddb460156cce1f676ce
parentb8d4c2b526aeee926c74ef7fc14ef0bd6376905c (diff)
downloadallocbench-721e672c897616e53f95b9deca7f8769024c19d5.tar.gz
allocbench-721e672c897616e53f95b9deca7f8769024c19d5.zip
add srcdir to globalvars
-rw-r--r--src/globalvars.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/globalvars.py b/src/globalvars.py
index 23ffa8a..9a7e958 100644
--- a/src/globalvars.py
+++ b/src/globalvars.py
@@ -11,9 +11,14 @@ verbosity = 0
"""Dict holding the allocators to compare"""
allocators = {}
+"""Directory of allocbench sources"""
+srcdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
+
+"""Source directory for all benchmarks"""
+benchsrcdir = os.path.join(srcdir, "benchmarks")
+
"""Root directory of allocbench"""
-allocbenchdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
-allocbenchdir = os.path.dirname(allocbenchdir)
+allocbenchdir = os.path.dirname(srcdir)
"""Path of the build directory"""
builddir = os.path.join(allocbenchdir, "build")
@@ -21,9 +26,6 @@ builddir = os.path.join(allocbenchdir, "build")
"""Directory were the benchmark results are stored"""
resdir = None
-"""Source directory for all benchmarks"""
-benchsrcdir = os.path.join(allocbenchdir, "src", "benchmarks")
-
"""List of available benchmarks"""
benchmarks = [e[:-3] for e in os.listdir(os.path.join(allocbenchdir, benchsrcdir))
if e[-3:] == ".py" and e != "__init__.py"]