"vscode:/vscode.git/clone" did not exist on "8b686288d0bf48e49abfa02cc52a01706ce35af9"
Commit 23b52514 authored by Hejing Li's avatar Hejing Li Committed by Jonas Kaufmann
Browse files

specification.py: import impl

parent 4e584719
......@@ -105,7 +105,8 @@ class Gem5Sim(Simulator):
def add(self, host: spec.Host):
self.hosts.append(host)
host.sim = 'gem5'
self.nics = host.nics
host.sim = self
self.name = f'{self.hosts[0].id}'
self.experiment.add_host(self)
......@@ -146,7 +147,7 @@ class Gem5Sim(Simulator):
for dev in self.nics:
cmd += (
f'--simbricks-pci=connect:{env.dev_pci_path(dev)}'
f'--simbricks-pci=connect:{env.dev_pci_path(dev.sim)}'
f':latency={self.pci_latency}ns'
f':sync_interval={self.sync_period}ns'
)
......
......@@ -95,7 +95,8 @@ class Host():
def config_str(self) -> str:
if self.sim == 'gem5':
import simbricks.splitsim.impl as impl
if type(self.sim) is impl.Gem5Sim :
cp_es = [] if self.nockp else ['m5 checkpoint']
exit_es = ['m5 exit']
else:
......@@ -304,4 +305,4 @@ class Sleep(AppConfig):
self.server_ip = server_ip
def run_cmds(self, node: Host) -> tp.List[str]:
return ['sleep']
\ No newline at end of file
return ['sleep 10']
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment