Recent Changes - Search:

Analysis

OpenMPI_optimized

Intel_MPI?

IBM_MPI?

FunctionsThrottling

ClusteringFolding

ClusteringAndFolding

Compile-Execute edit SideBar

Functions Throttling

Throttling is the mechanism which reduces the computational overhead associated with instrumenting a program and the size of the trace files. Many applications are constituted by functions which are called thousands of times without consuming a lot of time. However, Extrae does not provide an automatic procedure to exclude these functions thus we built our approach.

All instructions are tested with Intel Fortran compiler and we are interested in MPI applications.

  • Use gprof tool to profile your application:
    • Compile and link with -pg flag
    • Add the following to your .bashrc file:
      • export GMON_OUT_PREFIX='gmon.out-'`/bin/uname -n`
  • Execute your application, if everything worked you have gmon* files so many as your MPI processes
  • Now execute the gthrottling.sh script as follows:

./gthrottling.sh /path/to/executable/file.x

Rules for excluding a function:

  1. If there is no information about each call of a function is suspected if the total duration is less than 0.1% of the total execution time
  2. If a function is called more than 10,000 times:
    1. If its duration is less or equal to 5% ($1<=5, you can change this according to your application) of the total execution time
    2. If the duration of each call is less than 0.001s, then exclude it
  3. If the total execution time of this function is 0.0%, then remove it

You are going to see an output such as the following:

Input function list: function_names.txt 2467 functions
New function list: extrae_functions.txt 88 functions

This means that the binary is constituted by 2467 functions and 88 of them are the most important.

The file extrae_functions.txt contains the important functions list which should be instrument.

(↓)

Tip

Check the file extrae_functions.txt and if you find some functions that you know that are called by system and not for your application, you can remove them from the file

  • As Dyninst demands huge amount of memory for our application we followed this method:
    • Compile your application with -g -finstrument-functions . This way the compiler instruments the functions
    • However, is needed to declare a specific list of functions to Extrae with extraf.sh. Execute:

./extraf.sh path/to/executable/ extrae_functions.txt

The output is: echo "See the function names in the file extrae_functions_for_xml.txt"

The purpose of this mini tutorial is not to learn you how to use Extrae, however in order to declare this file to Extrae configuration, add the following to your XML file:

  <user-functions enabled="yes" list="/path/to/extrae_functions_for_xml.txt">
       <counters enabled="yes" />
  </user-functions>

Now you are ready to enjoy the instrumentation of the most important functions.

For any questions/bugs email to georgios [period] markomanolis [snail] bsc [period] es


This page may have a more recent version on pmwiki.org: PmWiki:FunctionsThrottling, and a talk page: PmWiki:FunctionsThrottling-Talk.

Edit - History - Print - Recent Changes - Search
Page last modified on February 21, 2014, at 11:10 AM