diff options
author | Jason Lowe-Power <jason@lowepower.com> | 2019-04-04 18:36:42 -0700 |
---|---|---|
committer | Jason Lowe-Power <jason@lowepower.com> | 2019-04-08 22:51:38 +0000 |
commit | 36bce3927e589dab1e4b446b75f2cff78cf1f531 (patch) | |
tree | c0cbaa7aa9a5d3c9398c81053073b5091d2d316d /configs/learning_gem5 | |
parent | 6bcd13fcc4d0c5eb3c7ced0ce6bc827e193415eb (diff) | |
download | gem5-36bce3927e589dab1e4b446b75f2cff78cf1f531.tar.xz |
configs: Fix import path error in learning_gem5 part3
Change-Id: I2c5cd22bded998bae8e7aa77e42e1b042ce1c5f5
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17869
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Diffstat (limited to 'configs/learning_gem5')
-rw-r--r-- | configs/learning_gem5/part3/ruby_test.py | 2 | ||||
-rw-r--r-- | configs/learning_gem5/part3/simple_ruby.py | 7 | ||||
-rw-r--r-- | configs/learning_gem5/part3/test_caches.py | 2 |
3 files changed, 7 insertions, 4 deletions
diff --git a/configs/learning_gem5/part3/ruby_test.py b/configs/learning_gem5/part3/ruby_test.py index 45c139bdf..a7ccbb576 100644 --- a/configs/learning_gem5/part3/ruby_test.py +++ b/configs/learning_gem5/part3/ruby_test.py @@ -42,7 +42,7 @@ import m5 # import all of the SimObjects from m5.objects import * -from .test_caches import TestCacheSystem +from test_caches import TestCacheSystem # create the system we are going to simulate system = System() diff --git a/configs/learning_gem5/part3/simple_ruby.py b/configs/learning_gem5/part3/simple_ruby.py index dda9e6dc7..bcd5044a1 100644 --- a/configs/learning_gem5/part3/simple_ruby.py +++ b/configs/learning_gem5/part3/simple_ruby.py @@ -47,7 +47,7 @@ from m5.objects import * # You can import ruby_caches_MI_example to use the MI_example protocol instead # of the MSI protocol -from .msi_caches import MyCacheSystem +from msi_caches import MyCacheSystem # create the system we are going to simulate system = System() @@ -80,7 +80,10 @@ system.caches.setup(system, system.cpu, [system.mem_ctrl]) isa = str(m5.defines.buildEnv['TARGET_ISA']).lower() # Run application and use the compiled ISA to find the binary -binary = 'tests/test-progs/threads/bin/' + isa + '/linux/threads' +# grab the specific path to the binary +thispath = os.path.dirname(os.path.realpath(__file__)) +binary = os.path.join(thispath, '../../../', 'tests/test-progs/threads/bin/', + isa, 'linux/threads') # Create a process for a simple "multi-threaded" application process = Process() diff --git a/configs/learning_gem5/part3/test_caches.py b/configs/learning_gem5/part3/test_caches.py index 4b17250ff..6495dc558 100644 --- a/configs/learning_gem5/part3/test_caches.py +++ b/configs/learning_gem5/part3/test_caches.py @@ -44,7 +44,7 @@ from m5.util import fatal from m5.objects import * -from .msi_caches import L1Cache, DirController, MyNetwork +from msi_caches import L1Cache, DirController, MyNetwork class TestCacheSystem(RubySystem): |