|
Linux Perf
|
#include "../perf.h"#include "util.h"#include "debug.h"#include <api/fs/fs.h>#include <sys/mman.h>#include <sys/stat.h>#include <sys/utsname.h>#include <dirent.h>#include <fcntl.h>#include <inttypes.h>#include <signal.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <errno.h>#include <limits.h>#include <linux/kernel.h>#include <linux/log2.h>#include <linux/time64.h>#include <unistd.h>#include "strlist.h"
Go to the source code of this file.
Functions | |
| void | perf_set_singlethreaded (void) |
| void | perf_set_multithreaded (void) |
| static void | cache_line_size (int *cacheline_sizep) |
| int | cacheline_size (void) |
| int | sysctl__max_stack (void) |
| void | event_attr_init (struct perf_event_attr *attr) |
| int | mkdir_p (char *path, mode_t mode) |
| int | rm_rf (const char *path) |
| bool | lsdir_no_dot_filter (const char *name __maybe_unused, struct dirent *d) |
| struct strlist * | lsdir (const char *name, bool(*filter)(const char *, struct dirent *)) |
| static int | slow_copyfile (const char *from, const char *to, struct nsinfo *nsi) |
| static int | copyfile_offset (int ifd, loff_t off_in, int ofd, loff_t off_out, u64 size) |
| static int | copyfile_mode_ns (const char *from, const char *to, mode_t mode, struct nsinfo *nsi) |
| int | copyfile_ns (const char *from, const char *to, struct nsinfo *nsi) |
| int | copyfile_mode (const char *from, const char *to, mode_t mode) |
| int | copyfile (const char *from, const char *to) |
| static ssize_t | ion (bool is_read, int fd, void *buf, size_t n) |
| ssize_t | readn (int fd, void *buf, size_t n) |
| ssize_t | writen (int fd, const void *buf, size_t n) |
| size_t | hex_width (u64 v) |
| int | hex2u64 (const char *ptr, u64 *long_val) |
| int | perf_event_paranoid (void) |
| static int | fetch_ubuntu_kernel_version (unsigned int *puint) |
| int | fetch_kernel_version (unsigned int *puint, char *str, size_t str_size) |
| const char * | perf_tip (const char *dirpath) |
Variables | |
| bool | perf_singlethreaded = true |
| unsigned int | page_size |
| int | sysctl_perf_event_max_stack = PERF_MAX_STACK_DEPTH |
| int | sysctl_perf_event_max_contexts_per_stack = PERF_MAX_CONTEXTS_PER_STACK |
| bool | test_attr__enabled |
| bool | perf_host = true |
| bool | perf_guest = false |
| int cacheline_size | ( | void | ) |
| int copyfile | ( | const char * | from, |
| const char * | to | ||
| ) |
| int copyfile_mode | ( | const char * | from, |
| const char * | to, | ||
| mode_t | mode | ||
| ) |
|
static |
| int copyfile_ns | ( | const char * | from, |
| const char * | to, | ||
| struct nsinfo * | nsi | ||
| ) |
|
static |
| int fetch_kernel_version | ( | unsigned int * | puint, |
| char * | str, | ||
| size_t | str_size | ||
| ) |
|
static |
|
static |
| struct strlist* lsdir | ( | const char * | name, |
| bool(*)(const char *, struct dirent *) | filter | ||
| ) |
| bool lsdir_no_dot_filter | ( | const char *name | __maybe_unused, |
| struct dirent * | d | ||
| ) |
| const char* perf_tip | ( | const char * | dirpath | ) |
| ssize_t readn | ( | int | fd, |
| void * | buf, | ||
| size_t | n | ||
| ) |
| int rm_rf | ( | const char * | path | ) |
|
static |
| ssize_t writen | ( | int | fd, |
| const void * | buf, | ||
| size_t | n | ||
| ) |
| int sysctl_perf_event_max_contexts_per_stack = PERF_MAX_CONTEXTS_PER_STACK |