File: energy_link.java.tesh

package info (click to toggle)
simgrid 4.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 39,192 kB
  • sloc: cpp: 124,913; ansic: 66,744; python: 8,560; java: 6,773; fortran: 6,079; f90: 5,123; xml: 4,587; sh: 2,194; perl: 1,436; makefile: 111; lisp: 49; javascript: 7; sed: 6
file content (29 lines) | stat: -rw-r--r-- 1,870 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/usr/bin/env tesh

p Testing the mechanism for computing link energy consumption (using CM02 as a network model)

$ ${javacmd} -cp ../../simgrid.jar:energy_link.jar energy_link ${platfdir}/energy_platform.xml  "--log=root.fmt:[%10.6r]%e(%i:%a@%h)%e%m%n" --cfg=network/model:CM02 --cfg=network/crosstraffic:no
> [  0.000000] (0:maestro@) Configuration change: Set 'network/model' to 'CM02'
> [  0.000000] (0:maestro@) Configuration change: Set 'network/crosstraffic' to 'no'
> [  0.000000] (0:maestro@) Using regular java threads.
> [  0.000000] (0:maestro@) Activating the SimGrid link energy plugin
> [  0.000000] (1:sender@MyHost1) Send 25000 bytes, in 1 flows
> [  0.000000] (2:receiver@MyHost2) Receiving 1 flows ...
> [ 10.250000] (2:receiver@MyHost2) receiver done.
> [ 10.250000] (1:sender@MyHost1) sender done.
> [ 10.250000] (0:maestro@) Total energy over all links: 10.750000
> [ 10.250000] (0:maestro@) Energy consumption of link 'bus': 10.750000 Joules

p And now test with 500000 bytes

$ ${javacmd} -cp ../../simgrid.jar:energy_link.jar energy_link ${platfdir}/energy_platform.xml 1 50000000 "--log=root.fmt:[%10.6r]%e(%i:%a@%h)%e%m%n" --cfg=network/model:CM02 --cfg=network/crosstraffic:no
> [  0.000000] (0:maestro@) Configuration change: Set 'network/model' to 'CM02'
> [  0.000000] (0:maestro@) Configuration change: Set 'network/crosstraffic' to 'no'
> [  0.000000] (0:maestro@) Using regular java threads.
> [  0.000000] (0:maestro@) Activating the SimGrid link energy plugin
> [  0.000000] (1:sender@MyHost1) Send 50000000 bytes, in 1 flows
> [  0.000000] (2:receiver@MyHost2) Receiving 1 flows ...
> [510.000000] (2:receiver@MyHost2) receiver done.
> [510.000000] (1:sender@MyHost1) sender done.
> [510.000000] (0:maestro@) Total energy over all links: 1510.000000
> [510.000000] (0:maestro@) Energy consumption of link 'bus': 1510.000000 Joules