-
Notifications
You must be signed in to change notification settings - Fork 13
pj_dump
Running pj_dump --help
gives you a good overview of what the tool does. Here's what you'd get (as of February 2017):
$ pj_dump --help
Usage: pj_dump [OPTION...] [FILE]
Dumps FILE, or standard input, in a CSV-like textual format
-a, --stop-at=TIME Stop the trace simulation at TIME
-c, --container Print container hierarchy in stdout
-d, --dot Print type hierarchy in dot format in stdout
-e, --end=END Dump ends at timestamp END (instead of EOF)
--entity-hierarchy=FILE Output the entity hierarchy to FILE (CSV)
-f, --flex Use flex-based file reader
-h, --header Print CSV header with column names
-i, --no-imbrication No imbrication levels (push and pop become sets)
-l, --float-precision=PRECISION
Precision of floating point numbers
-n, --no-strict Support old field names in event definitions
-p, --probabilistic=TYPENAME Dump global states based on TYPENAME
-q, --quiet Do not dump, only simulate
-s, --start=START Dump starts at timestamp START (instead of 0)
-t, --time Print number of seconds to simulate input
--type-hierarchy=FILE Output the type hierarchy to FILE (CSV)
-u, --user-defined Dump user-defined fields
-z, --ignore-incomplete-links Ignore incomplete links (not recommended)
-?, --help Give this help list
--usage Give a short usage message
-v, --version Print version of this binary
Mandatory or optional arguments to long options are also mandatory or optional
for any corresponding short options.
It's easier to understand what is written here if you are acquainted to the Paje terminology (Container, State, Variable, Link, Event and the information attached to each of these). Take a look to the description of the Paje File Format for further details.
The contents of the lines generated by pj_dump
are separated by
commas, defining the columns. So, a line like this:
Container, 0, LINK, 0, 4.48514, 4.48514, 9
has seven columns. The first column is always one of: Container,
State, Variable, Event or Link. The remaining columns of the line have
specific information depending on the first column. Here's a synthetic description of the
five different types of lines you'll find as output of pj_dump
:
Container, parentContainer, containerType, startTime, endTime, duration, name
State, container, stateType, startTime, endTime, duration, imbrication, value
Variable, container, variableType, startTime, endTime, duration, value
Event, container, eventType, time, value
Link, container, linkType, startTime, endTime, duration, value, startContainer, endContainer
See below a detailed description with examples for each of them.
All lines starting with Container look like this:
Container, 0, HOST, 0, 4.48514, 4.48514, Tremblay
- "Container"
- "0" - The name of the parent container
- "HOST" - The type of this container
- "0" - The starting time
- "4.48514" - The finish time
- "4.48514" -The duration
- "Tremblay" - The name of this container
All lines starting with State look like this:
State, node48, SERVICE, 691, 692, 1, 0, booked
- "State"
- "node48" - The name of the container
- "SERVICE" - The type of this state
- "691" - The starting time
- "692" - The finish time
- "1" - The duration
- "0" - The imbrication level
- "booked" - The value of the state
All lines starting with Variable look like this:
Variable, Tremblay, pcompute, 2.15357, 2.17013, 0.016554, 9.8095e+07
- "Variable"
- "Tremblay" - The name of the container
- "pcompute" - The name of the variable
- "2.15357" - The starting time
- "2.17013" - The ending time
- "0.016554" - The duration
- "9.8095e+07" - The value of the variable
All lines starting with Event look like this:
Event, Tremblay, msmark, 3.4286, finish_send_tasks
- "Event"
- "Tremblay" - The name of the container
- "msmark" - The name of the event
- "3.4286" - The instant in time when this event took place
- "finish_send_tasks" - The value of the event
All lines starting with Link look like this:
Link, 0, 0-HOST1-LINK4, 0, 0, 0, G, Tremblay, 9, mpi_123
- "Link"
- "0" - The name of the container
- "0-HOST1-LINK4" - The type of this link
- "0" - The starting time
- "0" - The ending time
- "0" - The duration
- "G" - The value of this link
- "Tremblay" - The starting container
- "9" - The ending container
- "mpi_123" - The unique key
According to the description of the Paje File
Format,
a link is formed by two events: PajeStartLink and PajeEndLink. These
events are matched by the Paje Simulator using a key that is provided
in the trace file. If one of these two events are missing for some
arbitrary reason and the trace file ends (or the container is
destroyed), you'll have a simulation with incomplete
links. Generally, the Paje Simulator, and by consequence pj_dump
,
consider these links as errors, and list them in the following manner:
$ ./pj_dump ~/tracefile.trace
List of incomplete links in container '0':
Link, 0, MSG_PROCESS_TASK_LINK, 0, -1, 0, SR, broadcaster-12, NULL
Link, 0, MSG_PROCESS_TASK_LINK, 0.00013, -1, 0, SR, broadcaster-13, NULL
Link, 0, MSG_PROCESS_TASK_LINK, 0.002868, -1, 0, SR, broadcaster-13, NULL
(...)
PajeLinkException: Incomplete links at the end of container with name '0'
The best action when this happens is to fix the tracer or the
converter that generated the trace, since it indicates probably some
error during the execution. If you think that this error is
acceptable, you can provide the -z
switch to pj_dump
to tell the
Paje Simulator to ignore incomplete links. All the trace file will be
dumped and all errors concerning incomplete links will be silently
ignored. Use with caution.