Linux Kernel
3.7.1
|
#include "util.h"
#include <sys/types.h>
#include <byteswap.h>
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <linux/list.h>
#include <linux/kernel.h>
#include <linux/bitops.h>
#include <sys/utsname.h>
#include "evlist.h"
#include "evsel.h"
#include "header.h"
#include "../perf.h"
#include "trace-event.h"
#include "session.h"
#include "symbol.h"
#include "debug.h"
#include "cpumap.h"
#include "pmu.h"
#include "vdso.h"
#include "strbuf.h"
Go to the source code of this file.
Data Structures | |
struct | perf_file_attr |
struct | cpu_topo |
struct | feature_ops |
struct | header_print_data |
Macros | |
#define | _FILE_OFFSET_BITS 64 |
#define | PERF_MAGIC __perf_magic2 |
#define | NAME_ALIGN 64 |
#define | dsos__for_each_with_build_id(pos, head) |
#define | CPUINFO_PROC NULL |
#define | CORE_SIB_FMT "/sys/devices/system/cpu/cpu%d/topology/core_siblings_list" |
#define | THRD_SIB_FMT "/sys/devices/system/cpu/cpu%d/topology/thread_siblings_list" |
#define | FEAT_OPA(n, func) [n] = { .name = #n, .write = write_##func, .print = print_##func } |
#define | FEAT_OPP(n, func) |
#define | FEAT_OPF(n, func) |
#define | print_tracing_data NULL |
#define | print_build_id NULL |
#define | PERF_PIPE_HDR_VER0 16 |
#define CPUINFO_PROC NULL |
|
read |
read_persistent_clock - Return time from the persistent clock.
Weak dummy function for arches that do not yet support it. Reads the time from the battery backed persistent clock. Returns a timespec with tv_sec=0 and tv_nsec=0 if unsupported.
XXX - Do be sure to remove it once all arches implement it.
read_boot_clock - Return time of the system start.
Weak dummy function for arches that do not yet support it. Function to read the exact time the system has been started. Returns a timespec with tv_sec=0 and tv_nsec=0 if unsupported.
XXX - Do be sure to remove it once all arches implement it.
__iowrite32_copy - copy data to MMIO space, in 32-bit units : destination, in MMIO space (must be 32-bit aligned) : source (must be 32-bit aligned) : number of 32-bit quantities to copy
Copy data from kernel space to MMIO space, in units of 32 bits at a time. Order of access is not guaranteed, nor is a memory barrier performed afterwards.
__iowrite64_copy - copy data to MMIO space, in 64-bit or 32-bit units : destination, in MMIO space (must be 64-bit aligned) : source (must be 64-bit aligned) : number of 64-bit quantities to copy
Copy data from kernel space to MMIO space, in units of 32 or 64 bits at a time. Order of access is not guaranteed, nor is a memory barrier performed afterwards.
get_user_pages_fast() - pin user pages in memory : starting user address : number of pages from start to pin : whether pages will be written to : array that receives pointers to the pages pinned. Should be at least nr_pages long.
Returns number of pages pinned. This may be fewer than the number requested. If nr_pages is 0 or negative, returns 0. If no pages were pinned, returns -errno.
get_user_pages_fast provides equivalent functionality to get_user_pages, operating on current and current->mm, with force=0 and vma=NULL. However unlike get_user_pages, it must be called without mmap_sem held.
get_user_pages_fast may take mmap_sem and page table locks, so no assumptions can be made about lack of locking. get_user_pages_fast is to be implemented in a way that is advantageous (vs get_user_pages()) when the user memory area is already faulted in and present in ptes. However if the pages have to be faulted in, it may turn out to be slightly slower so callers need to carefully consider what to use. On many architectures, get_user_pages_fast simply falls back to get_user_pages.
int perf_event__process_attr | ( | union perf_event * | event, |
struct perf_evlist ** | pevlist | ||
) |
int perf_event__process_build_id | ( | struct perf_tool *tool | __maybe_unused, |
union perf_event * | event, | ||
struct perf_session * | session | ||
) |
int perf_event__process_event_type | ( | struct perf_tool *tool | __maybe_unused, |
union perf_event * | event | ||
) |
int perf_event__process_tracing_data | ( | union perf_event * | event, |
struct perf_session * | session | ||
) |
int perf_event__synthesize_attr | ( | struct perf_tool * | tool, |
struct perf_event_attr * | attr, | ||
u32 | ids, | ||
u64 * | id, | ||
perf_event__handler_t | process | ||
) |
int perf_event__synthesize_attrs | ( | struct perf_tool * | tool, |
struct perf_session * | session, | ||
perf_event__handler_t | process | ||
) |
int perf_event__synthesize_tracing_data | ( | struct perf_tool * | tool, |
int | fd, | ||
struct perf_evlist * | evlist, | ||
perf_event__handler_t | process | ||
) |
int perf_file_header__read | ( | struct perf_file_header * | header, |
struct perf_header * | ph, | ||
int | fd | ||
) |
void perf_header__clear_feat | ( | struct perf_header * | header, |
int | feat | ||
) |
int perf_header__fprintf_info | ( | struct perf_session * | session, |
FILE * | fp, | ||
bool | full | ||
) |
bool perf_header__has_feat | ( | const struct perf_header * | header, |
int | feat | ||
) |
void perf_header__set_feat | ( | struct perf_header * | header, |
int | feat | ||
) |
int perf_session__read_header | ( | struct perf_session * | session, |
int | fd | ||
) |
int perf_session__write_header | ( | struct perf_session * | session, |
struct perf_evlist * | evlist, | ||
int | fd, | ||
bool | at_exit | ||
) |