#include <sys/types.h>
#include <iostream>
#include "operf_utils.h"
#include "operf_mangling.h"
#include "operf_kernel.h"
#include "operf_sfile.h"
#include "operf_counter.h"
#include "op_file.h"
#include "op_sample_file.h"
#include "op_mangle.h"
#include "op_events.h"
#include "op_libiberty.h"
#include "cverb.h"
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
Go to the source code of this file.
Functions | |
static const char * | mangle_anon (struct operf_sfile const *anon) |
static char * | mangle_filename (struct operf_sfile *last, struct operf_sfile const *sf, int counter, int cg) |
static void | fill_header (struct opd_header *header, unsigned long counter, vma_t anon_start, vma_t cg_to_anon_start, int is_kernel, int cg_to_is_kernel, int spu_samples, uint64_t embed_offset, time_t mtime) |
int | operf_open_sample_file (odb_t *file, struct operf_sfile *last, struct operf_sfile *sf, int counter, int cg) |
Variables | |
operf_read | operfRead |
op_cpu | cpu_type |
double | cpu_speed |
static void fill_header | ( | struct opd_header * | header, | |
unsigned long | counter, | |||
vma_t | anon_start, | |||
vma_t | cg_to_anon_start, | |||
int | is_kernel, | |||
int | cg_to_is_kernel, | |||
int | spu_samples, | |||
uint64_t | embed_offset, | |||
time_t | mtime | |||
) | [static] |
Definition at line 109 of file operf_mangling.cpp.
References opd_header::anon_start, opd_header::cg_to_anon_start, opd_header::cg_to_is_kernel, cpu_speed, opd_header::cpu_speed, opd_header::cpu_type, opd_header::ctr_count, opd_header::ctr_event, opd_header::ctr_um, opd_header::embedded_offset, operf_read::get_event_by_counter(), opd_header::is_kernel, opd_header::magic, opd_header::mtime, OPD_MAGIC, OPD_VERSION, opd_header::spu_profile, and opd_header::version.
static const char* mangle_anon | ( | struct operf_sfile const * | anon | ) | [static] |
Definition at line 41 of file operf_mangling.cpp.
References operf_sfile::end_addr, operf_kernel_image::name, operf_sfile::start_addr, and operf_sfile::tgid.
Referenced by mangle_filename().
static char* mangle_filename | ( | struct operf_sfile * | last, | |
struct operf_sfile const * | sf, | |||
int | counter, | |||
int | cg | |||
) | [static] |
Definition at line 52 of file operf_mangling.cpp.
References mangle_values::anon_name, operf_sfile::app_filename, mangle_values::cg_image_name, mangle_values::count, operf_sfile::cpu, mangle_values::cpu, mangle_values::dep_name, mangle_values::event_name, mangle_values::flags, operf_read::get_event_by_counter(), operf_sfile::image_name, mangle_values::image_name, operf_sfile::is_anon, operf_sfile::kernel, mangle_anon(), MANGLE_ANON, MANGLE_CALLGRAPH, MANGLE_CG_ANON, MANGLE_CPU, MANGLE_KERNEL, MANGLE_TGID, MANGLE_TID, operf_kernel_image::name, op_mangle_filename(), operf_options::separate_cpu, operf_options::separate_thread, operf_sfile::tgid, mangle_values::tgid, operf_sfile::tid, mangle_values::tid, and mangle_values::unit_mask.
Referenced by operf_open_sample_file().
int operf_open_sample_file | ( | odb_t * | file, | |
struct operf_sfile * | last, | |||
struct operf_sfile * | sf, | |||
int | counter, | |||
int | cg | |||
) |
Definition at line 133 of file operf_mangling.cpp.
References create_path(), cverb, fill_header(), operf_sfile::image_name, operf_sfile::is_anon, operf_sfile::kernel, mangle_filename(), operf_kernel_image::name, odb_get_data(), odb_open(), ODB_RDWR, op_get_mtime(), operf_sfile_get(), operf_sfile_lru_clear(), operf_sfile_put(), operf_sfile::start_addr, and vsfile.
Referenced by get_file().
Definition at line 55 of file oprofiled.c.