Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ycai
simbricks
Commits
242cae8e
Commit
242cae8e
authored
Jun 19, 2020
by
Antoine Kaufmann
Browse files
experiments: add qemu-ns3-dumbbell-pair
parent
f7d76917
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
0 deletions
+38
-0
experiments/Makefile
experiments/Makefile
+1
-0
experiments/common-functions.sh
experiments/common-functions.sh
+23
-0
experiments/experiments/qemu-ns3-dumbbell-pair.sh
experiments/experiments/qemu-ns3-dumbbell-pair.sh
+14
-0
No files found.
experiments/Makefile
View file @
242cae8e
...
...
@@ -13,6 +13,7 @@ EXPERIMENTS := \
gem5-kvm-corundum-bm-pair
\
gem5-timing-corundum-verilator-pair
\
qemu-ns3-bridge-pair
\
qemu-ns3-dumbbell-pair
\
BUILDDIR
:=
build
OUTDIR
:=
out
...
...
experiments/common-functions.sh
View file @
242cae8e
...
...
@@ -146,6 +146,29 @@ run_ns3_bridge() {
return
$pid
}
# Args:
# - Instance name
# - Left Port names
# - Right Port names
# - Other args
run_ns3_dumbbell
()
{
ports
=
""
for
p
in
$2
;
do
epath
=
"
`
readlink
-f
$OUTDIR
/eth.
$p
`
"
ports
=
"
$ports
--CosimPortLeft=
$epath
"
done
for
p
in
$3
;
do
epath
=
"
`
readlink
-f
$OUTDIR
/eth.
$p
`
"
ports
=
"
$ports
--CosimPortRight=
$epath
"
done
$NS3_BASE
/cosim-run.sh cosim-dumbbell-example
\
$ports
$4
&>
$OUTDIR
/ns3_bridge.
$1
.log &
pid
=
$!
ALL_PIDS
=
"
$ALL_PIDS
$pid
"
return
$pid
}
cleanup
()
{
echo
Cleaning up
for
p
in
$ALL_PIDS
;
do
...
...
experiments/experiments/qemu-ns3-dumbbell-pair.sh
0 → 100644
View file @
242cae8e
#!/bin/bash
source
common-functions.sh
init_out qemu-ns3-dumbbell-pair
run_corundum_bm a
run_corundum_bm b
sleep
0.5
run_ns3_dumbbell ab
"a"
"b"
run_qemu a a build/qemu-pair-server.tar
run_qemu b b build/qemu-pair-client.tar
client_pid
=
$!
wait
$client_pid
cleanup
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment