Commit 2ecbc4bf authored by Jonathan Jenkins's avatar Jonathan Jenkins

Added new example program showing new codes features

parent f1bd727f
ifndef CODESBASE
$(error CODESBASE is undefined, see README.txt)
endif
ifndef CODESNET
$(error CODESNET is undefined, see README.txt)
endif
ifndef ROSS
$(error ROSS is undefined, see README.txt)
endif
# ross conflates CFLAGS with CPPFLAGS, so use just this one
override CPPFLAGS += $(shell $(ROSS)/bin/ross-config --cflags) -I$(CODESBASE)/include -I$(CODESNET)/include/codes
CC = $(shell $(ROSS)/bin/ross-config --cc)
LDFLAGS = $(shell $(ROSS)/bin/ross-config --ldflags) -L$(CODESBASE)/lib -L$(CODESNET)/lib
LDLIBS = $(shell $(ROSS)/bin/ross-config --libs) -lcodes-net -lcodes-base
example: example.c
clean:
rm -f example
This example program shows some features enabled by the new annotation-based
configuration and mapping APIs in codes-base, as well as support for them in
codes-net. The example does not exhaustively show all new features added - for
more details, see configuration.h, codes-mapping.h, and model-net.h in
codes-net.
Specifically, some features shown are:
* Use of annotated configuration to initialize three separate network models.
Note that they are all the same network model, just with different
parameterizations. This includes both the configuration file itself as well as
interaction in the code between components with different annotations.
* Addressing at various levels in both LP type-specific namespaces and
model-net namespaces (network id, annotation tuples).
* The updated registration/configuration sequence in main.
This diff is collapsed.
LPGROUPS {
## cluster foo
FOO_CLUSTER {
repetitions="12";
node="1";
modelnet_simplenet@foo="1";
}
FOO_FORWARDERS {
repetitions="4";
forwarder="1";
modelnet_simplenet@foo="1";
modelnet_simplenet="1";
}
## cluster bar
BAR_CLUSTER {
repetitions="12";
node="1";
modelnet_simplenet@bar="1";
}
BAR_FORWARDERS {
repetitions="4";
forwarder="1";
modelnet_simplenet@bar="1";
modelnet_simplenet="1";
}
}
PARAMS {
## ROSS parameters
message_size="256";
## global modelnet parameters
modelnet_order=("simplenet");
## foo cluster network parameters
packet_size@foo="8192";
modelnet_scheduler@foo="fcfs";
net_startup_ns@foo="1.5";
net_bw_mbps@foo="10000";
## bar cluster network parameters
packet_size@bar="2048";
modelnet_scheduler@bar="round-robin";
net_startup_ns@bar="3.0";
net_bw_mbps@bar="15000";
## forwarding network parameters
packet_size="4096";
modelnet_scheduler="fcfs";
net_startup_ns="8.0";
net_bw_mbps="5000";
}
run_params {
num_reqs="5";
payload_sz="16384";
}
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