| # Gaudi Framework, version v22r2 |

Home |  | Generated: Tue May 10 2011

Classes | Defines | Variables

# PerfMonAuditor.cpp File Reference

`#include "GaudiKernel/Auditor.h"`
`#include "GaudiKernel/IToolSvc.h"`
`#include "GaudiKernel/IIncidentListener.h"`
`#include "GaudiKernel/IIncidentSvc.h"`
`#include "GaudiKernel/VectorMap.h"`
`#include "GaudiKernel/HashMap.h"`
`#include "GaudiKernel/AudFactory.h"`
`#include "GaudiKernel/MsgStream.h"`
`#include <iostream>`
`#include <string>`
`#include <cstring>`
`#include <fstream>`
`#include <perfmon/pfmlib.h>`
`#include <perfmon/pfmlib_core.h>`
`#include <perfmon/pfmlib_intel_nhm.h>`
`#include <vector>`
`#include <map>`
`#include <utility>`
`#include <sstream>`
`#include <perfmon/perfmon.h>`
`#include <perfmon/perfmon_dfl_smpl.h>`
`#include <sys/types.h>`
`#include <stdio.h>`
`#include <stdlib.h>`
`#include <stdarg.h>`
`#include <errno.h>`
`#include <unistd.h>`
`#include <string.h>`
`#include <signal.h>`
`#include <stdint.h>`
`#include <getopt.h>`
`#include <time.h>`
`#include <sys/ptrace.h>`
`#include <sys/wait.h>`
`#include <sys/mman.h>`
`#include <sys/time.h>`
`#include <sys/resource.h>`
`#include <fcntl.h>`
`#include <zlib.h>`
`#include <algorithm>`
`#include <list>`
`#include <stack>`
`#include <cmath>`
`#include <sys/stat.h>`
`#include "IgHook_IgHookTrace.h"`
`#include <dlfcn.h>`
Include dependency graph for PerfMonAuditor.cpp:

Go to the source code of this file.

## Classes
class | PerfMonAuditor
| Performance Monitoring Auditor that uses Perfmon2 library to monitor algorithms. More...
## Defines
#define | MAX_EVT_NAME_LEN 256
#define | NUM_PMCS PFMLIB_MAX_PMCS
#define | NUM_PMDS PFMLIB_MAX_PMDS
#define | FMT_NAME PFM_DFL_SMPL_NAME
#define | BPL (sizeof(uint64_t)<<3)
#define | LBPL 6
#define | SYM_NAME_MAX_LENGTH 10000
#define | MAX_OUTPUT_FILENAME_LENGTH 1024
#define | MAX_EVENT_NAME_LENGTH 500
#define | MAX_PREFIX_NAME_LENGTH 1024
#define | FILENAME_MAX_LENGTH 1024
#define | MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS 4
#define | cpuid(func, ax, bx, cx, dx) __asm__ __volatile__ ("cpuid": "=a" (ax), "=b" (bx), "=c" (cx), "=d" (dx) : "a" (func));
## Variables
static pfarg_pmd_t | pd_smpl [NUM_PMDS]
static uint64_t | collected_samples
static uint64_t | collected_partial
static int | ctx_fd
static pfm_dfl_smpl_hdr_t * | hdr
static uint64_t | ovfl_count
static size_t | entry_size
static unsigned int | num_smpl_pmds
static std::vector< std::map < std::string, std::map < unsigned long, unsigned int > > > | samples (MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS)
static std::vector< std::map < std::string, std::vector < unsigned long int > > > | results (MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS)
static uint64_t | last_overflow
static uint64_t | last_count
static std::string | current_module
static int | sp [MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS]
static std::stack< std::pair < INamedInterface *, std::vector< unsigned long int > > > | alg_stack

## Define Documentation

#define BPL (sizeof(uint64_t)<<3)

Definition at line 74 of file PerfMonAuditor.cpp.

#define cpuid | ( |  | func,
|  |  | ax,
|  |  | bx,
|  |  | cx,
|  |  | dx
| ) |  | __asm__ __volatile__ ("cpuid": "=a" (ax), "=b" (bx), "=c" (cx), "=d" (dx) : "a" (func));

Definition at line 85 of file PerfMonAuditor.cpp.

#define FILENAME_MAX_LENGTH 1024

Definition at line 81 of file PerfMonAuditor.cpp.

#define FMT_NAME PFM_DFL_SMPL_NAME

Definition at line 73 of file PerfMonAuditor.cpp.

#define LBPL 6

Definition at line 75 of file PerfMonAuditor.cpp.

#define MAX_EVENT_NAME_LENGTH 500

Definition at line 79 of file PerfMonAuditor.cpp.

#define MAX_EVT_NAME_LEN 256

Definition at line 70 of file PerfMonAuditor.cpp.

#define MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS 4

Definition at line 83 of file PerfMonAuditor.cpp.

#define MAX_OUTPUT_FILENAME_LENGTH 1024

Definition at line 78 of file PerfMonAuditor.cpp.

#define MAX_PREFIX_NAME_LENGTH 1024

Definition at line 80 of file PerfMonAuditor.cpp.

#define NUM_PMCS PFMLIB_MAX_PMCS

Definition at line 71 of file PerfMonAuditor.cpp.

#define NUM_PMDS PFMLIB_MAX_PMDS

Definition at line 72 of file PerfMonAuditor.cpp.

#define SYM_NAME_MAX_LENGTH 10000

Definition at line 77 of file PerfMonAuditor.cpp.

## Variable Documentation

std::stack<std::pair<INamedInterface *, std::vector<unsigned long int> > > alg_stack`[static]`

Definition at line 102 of file PerfMonAuditor.cpp.

uint64_t collected_partial

Definition at line 89 of file PerfMonAuditor.cpp.

uint64_t collected_samples`[static]`

Definition at line 89 of file PerfMonAuditor.cpp.

int ctx_fd`[static]`

Definition at line 90 of file PerfMonAuditor.cpp.

std::string current_module`[static]`

Definition at line 99 of file PerfMonAuditor.cpp.

size_t entry_size`[static]`

Definition at line 93 of file PerfMonAuditor.cpp.

pfm_dfl_smpl_hdr_t* hdr`[static]`

Definition at line 91 of file PerfMonAuditor.cpp.

uint64_t last_count`[static]`

Definition at line 98 of file PerfMonAuditor.cpp.

uint64_t last_overflow`[static]`

Definition at line 97 of file PerfMonAuditor.cpp.

unsigned int num_smpl_pmds`[static]`

Definition at line 94 of file PerfMonAuditor.cpp.

uint64_t ovfl_count`[static]`

Definition at line 92 of file PerfMonAuditor.cpp.

pfarg_pmd_t pd_smpl[NUM_PMDS]`[static]`

Definition at line 88 of file PerfMonAuditor.cpp.

std::vector<std::map<std::string, std::vector<unsigned long int> > > results(MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS)`[static]`

std::vector<std::map<std::string, std::map<unsigned long, unsigned int> > > samples(MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS)`[static]`

int sp[MAX_NUMBER_OF_PROGRAMMABLE_COUNTERS]`[static]`

Definition at line 100 of file PerfMonAuditor.cpp.

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines