Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
codes
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
38
Issues
38
List
Boards
Labels
Milestones
Merge Requests
8
Merge Requests
8
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
codes
codes
Commits
d603bf86
Commit
d603bf86
authored
Dec 13, 2013
by
Jonathan Jenkins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fleshing out example program, and other cleanups
parent
7b22be99
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
274 additions
and
131 deletions
+274
-131
doc/example/Makefile
doc/example/Makefile
+2
-12
doc/example/example.c
doc/example/example.c
+225
-102
doc/example/example.conf
doc/example/example.conf
+47
-0
doc/example/modelnet-test.conf
doc/example/modelnet-test.conf
+0
-17
No files found.
doc/example/Makefile
View file @
d603bf86
...
...
@@ -16,15 +16,5 @@ LDLIBS = $(shell $(ROSS)/bin/ross-config --libs) -lcodes-net -lcodes-base
example
:
example.c
#$(CC) $(ROSS_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) $(ROSS_LDFLAGS) $^ -o $@ -L$(ROSS)/lib -lROSS -lm -L$(CODESBASE)/lib -lcodes-base -L$(CODESNET)/lib -lcodes-net
check-env
:
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
clean
:
rm
-f
example
doc/example/example.c
View file @
d603bf86
This diff is collapsed.
Click to expand it.
doc/example/example.conf
0 → 100644
View file @
d603bf86
# the LPGROUPS set is required by all simulations using codes. Multiple groups
# can be entered (only one is here for our example), each consisting of a set
# of application- and codes-specific key-value pairs.
LPGROUPS
{
# in our simulation, we simply have a set of servers, each with
# point-to-point access to each other
SERVERS
{
# required: number of times to repeat the following key-value pairs
repetitions
=
"16"
;
# application-specific: parsed in main
server
=
"1"
;
# model-net-specific field defining the network backend. In this example,
# each server has one NIC, and each server are point-to-point connected
modelnet_simplenet
=
"1"
;
}
}
# required by CODES: miscellaneous parameters used in the simulation that
# don't fit in group definition.
PARAMS
{
# ROSS-specific parmeters:
# - message_size: ROSS expects you to upper bound your event message size.
# Going over this size will crash or otherwise destroy your
# simulation.
message_size
=
"256"
;
# model-net-specific parameters:
# - individual packet sizes for network operations
# (each "packet" is represented by an event)
# - independent of underlying network being used
packet_size
=
"512"
;
# - type of model to use (must match with corresponding LPGROUPS entry)
modelnet
=
"simplenet"
;
# - model-specific parameters
net_startup_ns
=
"1.5"
;
net_bw_mbps
=
"20000"
;
}
# custom parameter sets can also be added - this one isn't used in the
# simulation, but is included for illustrative purposes
blah
{
param1
=
"hello"
;
param2
=
"goodbye"
;
param3
=
"0.0001"
;
}
doc/example/modelnet-test.conf
deleted
100644 → 0
View file @
7b22be99
LPGROUPS
{
MODELNET_GRP
{
repetitions
=
"16"
;
server
=
"1"
;
modelnet_simplenet
=
"1"
;
}
}
PARAMS
{
packet_size
=
"512"
;
message_size
=
"256"
;
modelnet
=
"simplenet"
;
net_startup_ns
=
"1.5"
;
net_bw_mbps
=
"20000"
;
}
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