.. _nanos6-extrae-instrumentation: Generating Extrae traces ------------------------ .. index:: triple: Nanos6; Extrae; instrumentation To generate a Paraver trace using Extrae, the ``version.instrument`` configuration variable must be set to ``extrae`` before running the application. By default, the runtime will generate a trace as if ``EXTRAE_ON`` was set to 1. In addition, the ``EXTRAE_CONFIG_FILE`` environment variable can be set to an Extrae configuration file for fine tuning, for instance, to enable recording hardware counters. See: the `Extrae documentation `__. The amount of information generated in the Extrae traces can be controlled through the ``instrument.extrae.detail_level`` configuration option. Its value determines a level of detail that goes from 0, which is the least detailed, up to 8. The default level is 1. Lower levels incur in less overhead and produce smaller traces. Higher levels have more overhead, produce bigger traces, but are more precise and comtain more information. The information generated at each level is incremental and is the following: Level 0 Basic level Includes basic information about the runtime state and the execution of tasks. Counters about the number of tasks in the system are approximate and are sampled at periodic intervals. Level 1 Default level Counters about the number of tasks in the system are precise in terms of time and value. Adds communication records that link the point of instantiation of a task to the point where they start their execution. Adds communication records that link the point where a task get blocked to the point where a task unblocks it (makes it ready), and from that point to the point where the task actually resumes its execution. Adds communication records that show task dependency relations. The set of predecessors a task that is shown is limited to the set of tasks that have not finished their execution once said task has been instantiated. The links go from the end of the execution of a predecessor to the start of the execution of the successor. Levels 2 to 7 Unused Currently they do not add further information. Level 8 Very detailed level Adds communication records that link the end of the execution of a task to the point where its parent returns from a taskwait. The trace only contains links for the tasks that have not finished once their parent enters the taskwait. This information is only available at level 8, since it may make the trace significantly bigger. The runtime installation contains a set of already made Paraver configuration files at the following subdirectory:: $INSTALLATION_PREFIX/share/doc/nanos6/paraver-cfg/nanos6 Support for hardware counters is enabled through file specified in the ``EXTRAE_CONFIG_FILE`` environment variable. The procedure is explained in the `Extrae documentation `__. However, the ``instrument.extrae.as_threads`` configuration variable must also be set to ``true``. This is a temporary measure that is needed to produce correct hardware counter information. The resulting trace will expose the actual runtime threads, as opposed to the CPU view that is generated by default.