| FEAT 3
    Finite Element Analysis Toolbox | 
This pages describes the use of the LIKWID marker API within FEAT.
LIKWID (like i know what im doing) is a toolset of command line applications intended for performance measuring of sequential and parallel code. It can be build on most architectures under Linux operating systems and additonally supports Nvidia and AMD GPUs. Besides providing micro benchmarks and pinning capabilities, it also provides hardware performance counters, allowing for a more empirical reasoning about code performance. It works in multithreaded and MPI based parallization setups.
For information on how to generally install and use LIKWID, see LIKWID wiki. The following text expects the reader to know how to use LIKWID and only handles the specifics for FEAT.
LIKWID should be installed and findable by standard libarary lookups, else set the PATH variable or the likwid_ROOT accordingly. If you want to use LIKWID, you should provide the likwid configure flag when configuring FEAT, for example 
/path/to/feat3/configure gcc-opt-likwid
 which activates the LIKWID_PERFOM enviroment variable and activates the actual marker API.
In general, all marker api calls described henceforth are always defined, i.e. always be called without breaking your code, but if not activated by the corresponding flag are empty definition, hence do not change your actual application. The LIKWID_MARKER_INIT and LIKWID_MARKER_CLOSE call is automatically done in the runtime header guard. You could know use the standard LIKWID_MARKER_<..> calls, but in the likwid_marker.hpp additional MARKER calls are defined: 
FEAT_KERNEL_MARKER_* FEAT_APPLICATION_MARKER_* FEAT_SPECIAL_MARKER_* FEAT_NVMARKER_*
 where each marker variant provides REGISTER, START, STOP and GET calls. These flags can be explicitly activated by defining the –likwid_markers= configure flag. Possible values are kernel, app, special, cuda. Multiple flags can be activated by seperating them with a ',' without whitespaces. For example, if you want to activate kernel and application flags, provide 
--likwid_markers=kernel,app
 addtionally to the likwid configure flag.
By default, only the application flag is enabled. All deactivated api calls are empty definition, thus do not lead to any unexpected behavior.