summaryrefslogtreecommitdiff
path: root/src/python/m5
diff options
context:
space:
mode:
Diffstat (limited to 'src/python/m5')
-rw-r--r--src/python/m5/main.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/python/m5/main.py b/src/python/m5/main.py
index 904b241ca..80dbcb5aa 100644
--- a/src/python/m5/main.py
+++ b/src/python/m5/main.py
@@ -283,9 +283,10 @@ def main():
objects.ExecutionTrace.print_fetchseq = options.print_fetch_seq
objects.ExecutionTrace.print_cpseq = options.print_cpseq
- scope = { '__file__' : sys.argv[0] }
sys.argv = arguments
sys.path = [ os.path.dirname(sys.argv[0]) ] + sys.path
+
+ scope = { '__file__' : sys.argv[0] }
exec("import readline", scope)
execfile(sys.argv[0], scope)