plateform stringclasses 1
value | repo_name stringclasses 2
values | name stringlengths 1 78 | ext stringclasses 2
values | path stringlengths 15 1.11k | size int64 1 8.55M | source_encoding stringclasses 11
values | md5 stringlengths 32 32 | text stringlengths 0 8.49M |
|---|---|---|---|---|---|---|---|---|
google | android | thread | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/thread.c | 5,057 | utf_8 | 9ca6692babe912874c356a8d659a0da1 | #include "../perf.h"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "session.h"
#include "thread.h"
#include "thread-stack.h"
#include "util.h"
#include "debug.h"
#include "comm.h"
#include "unwind.h"
int thread__init_map_groups(struct thread *thread, struct machine *machine)
{
struct thread *lea... |
google | android | parse-options | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/parse-options.c | 20,502 | utf_8 | 48de0b3e7a940a19e9583d42261e9d9e | #include "util.h"
#include "parse-options.h"
#include "cache.h"
#include "header.h"
#include <linux/string.h>
#define OPT_SHORT 1
#define OPT_UNSET 2
static struct strbuf error_buf = STRBUF_INIT;
static int opterror(const struct option *opt, const char *reason, int flags)
{
if (flags & OPT_SHORT)
return error("sw... |
google | android | hist | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/hist.c | 37,291 | utf_8 | fa626091f1fd788af7ff492d33e994ef | #include "util.h"
#include "build-id.h"
#include "hist.h"
#include "session.h"
#include "sort.h"
#include "evlist.h"
#include "evsel.h"
#include "annotate.h"
#include "ui/progress.h"
#include <math.h>
static bool hists__filter_entry_by_dso(struct hists *hists,
struct hist_entry *he);
static bool hists__filt... |
google | android | evlist | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/evlist.c | 41,537 | utf_8 | 7ca2e9cd6944191611aa43aaf03a0aa6 | /*
*/
#include "util.h"
#include <api/fs/fs.h>
#include <poll.h>
#include "cpumap.h"
#include "thread_map.h"
#include "target.h"
#include "evlist.h"
#include "evsel.h"
#include "debug.h"
#include <unistd.h>
#include "parse-events.h"
#include "parse-options.h"
#include <sys/mman.h>
#include <linux/bitops.h>
#include <l... |
google | android | stat | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/stat.c | 7,455 | utf_8 | 04aca2c389ae1670e5e3e4e73b20dc5e | #include <math.h>
#include "stat.h"
#include "evlist.h"
#include "evsel.h"
#include "thread_map.h"
void update_stats(struct stats *stats, u64 val)
{
double delta;
stats->n++;
delta = val - stats->mean;
stats->mean += delta / stats->n;
stats->M2 += delta*(val - stats->mean);
if (val > stats->max)
stats->max =... |
google | android | quote | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/quote.c | 1,265 | utf_8 | fb53d259350a7b6fc10953415140efaa | #include "cache.h"
#include "quote.h"
/* Help to copy the thing properly quoted for the shell safety.
* any single quote is replaced with '\'', any exclamation point
* is replaced with '\!', and the whole thing is enclosed in a
*
* E.g.
* original sq_quote result
* name ==> name ==> 'name'
* ... |
google | android | cpumap | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/cpumap.c | 10,013 | utf_8 | 131036052dca6d360ef21cddb5846148 | #include "util.h"
#include <api/fs/fs.h>
#include "../perf.h"
#include "cpumap.h"
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include "asm/bug.h"
static struct cpu_map *cpu_map__default_new(void)
{
struct cpu_map *cpus;
int nr_cpus;
nr_cpus = sysconf(_SC_NPROCESSORS_ONLN);
if (nr_cpus < 0)
retur... |
google | android | path | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/path.c | 3,416 | utf_8 | 422232f1df723670ddcaad82377e03e1 | /*
* I'm tired of doing "vsnprintf()" etc just to open a
* file, so here's a "return static buffer with printf"
* interface for paths.
*
* It's obviously not thread-safe. Sue me. But it's quite
* useful for doing things like
*
* f = open(mkpath("%s/%s.perf", base, name), O_RDONLY);
*
* which is what it's de... |
google | android | trace-event | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/trace-event.c | 2,312 | utf_8 | 49062b9b384929d1314f5333b11da77e |
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <errno.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <linux/kernel.h>
#include <linux/err.h>
#include <traceevent/event-parse.h>
#include <api/fs/tracing_path.h>
#include "trace-event.h"
#include "machine.h"
#include "uti... |
google | android | counts | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/counts.c | 1,026 | utf_8 | 0732fe9f1a1439cae869cdab2b598e95 | #include <stdlib.h>
#include "evsel.h"
#include "counts.h"
struct perf_counts *perf_counts__new(int ncpus, int nthreads)
{
struct perf_counts *counts = zalloc(sizeof(*counts));
if (counts) {
struct xyarray *values;
values = xyarray__new(ncpus, nthreads, sizeof(struct perf_counts_values));
if (!values) {
f... |
google | android | symbol | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/symbol.c | 46,949 | utf_8 | ae85d3f31c1853fb6c4dcea3f5902da9 | #include <dirent.h>
#include <errno.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/param.h>
#include <fcntl.h>
#include <unistd.h>
#include <inttypes.h>
#include "build-id.h"
#include "util.h"
#include "debug.h"
#include "machine.h"
#include "sym... |
google | android | pmu | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/pmu.c | 22,497 | utf_8 | 8f244621d0fe981bcead2715960c5315 | #include <linux/list.h>
#include <linux/compiler.h>
#include <sys/types.h>
#include <unistd.h>
#include <stdio.h>
#include <stdbool.h>
#include <stdarg.h>
#include <dirent.h>
#include <api/fs/fs.h>
#include <locale.h>
#include "util.h"
#include "pmu.h"
#include "parse-events.h"
#include "cpumap.h"
struct perf_pmu_form... |
google | android | alias | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/alias.c | 1,433 | utf_8 | 59b7c4929d759c75ff2f67ae6b11dc7a | #include "cache.h"
static const char *alias_key;
static char *alias_val;
static int alias_lookup_cb(const char *k, const char *v,
void *cb __maybe_unused)
{
if (!prefixcmp(k, "alias.") && !strcmp(k+6, alias_key)) {
if (!v)
return config_error_nonbool(k);
alias_val = strdup(v);
return 0;
}
return 0;
}
... |
google | android | strbuf | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/strbuf.c | 3,088 | utf_8 | 5f01b6c09172508dae0a94a0e2247680 | #include "cache.h"
#include <linux/kernel.h>
int prefixcmp(const char *str, const char *prefix)
{
for (; ; str++, prefix++)
if (!*prefix)
return 0;
else if (*str != *prefix)
return (unsigned char)*prefix - (unsigned char)*str;
}
/*
* Used as the default ->buf value, so that people can always assume
* buf... |
google | android | sort | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/sort.c | 47,736 | utf_8 | 07cabbffac1d4dda876e0ec5d92054e8 | #include <sys/mman.h>
#include "sort.h"
#include "hist.h"
#include "comm.h"
#include "symbol.h"
#include "evsel.h"
regex_t parent_regex;
const char default_parent_pattern[] = "^sys_|^do_page_fault";
const char *parent_pattern = default_parent_pattern;
const char default_sort_order[] = "comm,dso,symbol";
const char de... |
google | android | vdso | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/vdso.c | 6,479 | utf_8 | 21846e400ea431b7e5e288c6f4eb4821 |
#include <unistd.h>
#include <stdio.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <linux/kernel.h>
#include "vdso.h"
#include "util.h"
#include "symbol.h"
#include "machine.h"
#include "thread.h"
#include "linux/string.h"
#include "debug.h"
/*
* ... |
google | android | levenshtein | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/levenshtein.c | 2,592 | utf_8 | 4488ae93a303f331fc6e679cd3589985 | #include "cache.h"
#include "levenshtein.h"
/*
* This function implements the Damerau-Levenshtein algorithm to
* calculate a distance between strings.
*
* Basically, it says how many letters need to be swapped, substituted,
* deleted from, or added to string1, at least, to get string2.
*
* The idea is to build ... |
google | android | debug | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/debug.c | 3,677 | utf_8 | d7aef02d3cda2b9e7052a18fbdd96168 | /* For general debugging purposes */
#include "../perf.h"
#include <string.h>
#include <stdarg.h>
#include <stdio.h>
#include "cache.h"
#include "color.h"
#include "event.h"
#include "debug.h"
#include "util.h"
#include "target.h"
#define NSECS_PER_SEC 1000000000ULL
#define NSECS_PER_USEC 1000ULL
int verbose;
boo... |
google | android | top | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/top.c | 3,555 | utf_8 | cc22d9ee627e830b028162479e11f98b | /*
*/
#include "cpumap.h"
#include "event.h"
#include "evlist.h"
#include "evsel.h"
#include "parse-events.h"
#include "symbol.h"
#include "top.h"
#include <inttypes.h>
#define SNPRINTF(buf, size, fmt, args...) \
({ \
size_t r = snprintf(buf, size, fmt, ## args); \
r > size ? size : r; \
})
size_t perf_top__header_... |
google | android | comm | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/comm.c | 2,239 | utf_8 | c0785a6ad7b7a5b1a2bf3e2bef961b6c | #include "comm.h"
#include "util.h"
#include <stdlib.h>
#include <stdio.h>
#include <linux/atomic.h>
struct comm_str {
char *str;
struct rb_node rb_node;
atomic_t refcnt;
};
/* Should perhaps be moved to struct machine */
static struct rb_root comm_str_root;
static struct comm_str *comm_str__get(struct comm_str *... |
google | android | trace-event-scripting | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/trace-event-scripting.c | 4,682 | utf_8 | 12d0f02c54e33645aa6e7a323683e193 | /*
* trace-event-scripting. Scripting engine common and initialization code.
*
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include "../perf.h"
#include "util.h"
#include "trace-event.h"
struct scri... |
google | android | string | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/string.c | 7,648 | utf_8 | 9bd4784f912169b5d0884a64c97227a3 | #include "util.h"
#include "linux/string.h"
#define K 1024LL
/*
* perf_atoll()
* Parse (\d+)(b|B|kb|KB|mb|MB|gb|GB|tb|TB) (e.g. "256MB")
* and return its numeric value
*/
s64 perf_atoll(const char *str)
{
s64 length;
char *p;
char c;
if (!isdigit(str[0]))
goto out_err;
length = strtoll(str, &p, 10);
switch ... |
google | android | thread_map | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/thread_map.c | 8,457 | utf_8 | aeaf25032b6faa096a2f09046010829a | #include <dirent.h>
#include <limits.h>
#include <stdbool.h>
#include <stdlib.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include "strlist.h"
#include <string.h>
#include <api/fs/fs.h>
#include "asm/bug.h"
#include "thread_map.h"
#include "util.h"
#include "debug.h"
/* Skip ... |
google | android | srcline | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/srcline.c | 6,089 | utf_8 | 326e3b69396a16b9d6812b8c40548182 | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <linux/kernel.h>
#include "util/dso.h"
#include "util/util.h"
#include "util/debug.h"
#include "symbol.h"
bool srcline_full_filename;
#ifdef HAVE_LIBBFD_SUPPORT
/*
* Implement addr2line using libbfd.
*/
#define PACKAGE "perf"
#include <bfd.h>
struct ... |
google | android | db-export | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/db-export.c | 9,423 | utf_8 | 9c3cea69d60b3af58c2847fea1387e4c | /*
* db-export.c: Support for exporting data suitable for import to a database
* more details.
*
*/
#include <errno.h>
#include "evsel.h"
#include "machine.h"
#include "thread.h"
#include "comm.h"
#include "symbol.h"
#include "event.h"
#include "util.h"
#include "thread-stack.h"
#include "db-export.h"
struct deferr... |
google | android | record | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/record.c | 6,096 | utf_8 | 8b5b6bf4f760ebf725bd328313bab387 | #include "evlist.h"
#include "evsel.h"
#include "cpumap.h"
#include "parse-events.h"
#include <api/fs/fs.h>
#include "util.h"
#include "cloexec.h"
typedef void (*setup_probe_fn_t)(struct perf_evsel *evsel);
static int perf_do_probe_api(setup_probe_fn_t fn, int cpu, const char *str)
{
struct perf_evlist *evlist;
struc... |
google | android | environment | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/environment.c | 229 | utf_8 | 96f795dc7573a03e499263a1b731b997 | /*
* We put all the perf config variables in this same object
* file, so that programs can link against the config parser
* without having to link against all the rest of perf.
*/
#include "cache.h"
int pager_use_color = 1;
|
google | android | llvm-utils | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/llvm-utils.c | 10,494 | utf_8 | 064d4e7590102f6e3a65c8790face736 | /*
*/
#include <stdio.h>
#include "util.h"
#include "debug.h"
#include "llvm-utils.h"
#include "cache.h"
#define CLANG_BPF_CMD_DEFAULT_TEMPLATE \
"$CLANG_EXEC -D__KERNEL__ -D__NR_CPUS__=$NR_CPUS "\
"-DLINUX_VERSION_CODE=$LINUX_VERSION_CODE " \
"$CLANG_OPTIONS $KERNEL_INC_OPTIONS " \
"-Wno-unused-value -Wno... |
google | android | rblist | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/rblist.c | 2,441 | utf_8 | 22eecf5f5c22cd089d82e3ba24c51efd | /*
* Based on strlist.c by:
*/
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include "rblist.h"
int rblist__add_node(struct rblist *rblist, const void *new_entry)
{
struct rb_node **p = &rblist->entries.rb_node;
struct rb_node *parent = NULL, *new_node;
while (*p != NULL) {
int rc;
parent = *p;
... |
google | android | dwarf-aux | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/dwarf-aux.c | 28,245 | utf_8 | 39413e4616b390cdb011057c22f06233 | /*
* dwarf-aux.c : libdw auxiliary interfaces
*
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#include <stdbool.h>
#include "util.h"
#include "debug.h"
#include "dwarf-aux.h"
/**
* cu_find_realpath - Find the realpath of the target file
*/
const char *cu_find_realpath(Dwarf_Di... |
google | android | trace-event-parse | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/trace-event-parse.c | 5,439 | utf_8 | a0aa8216747ae9299c5448c1c7b1e934 | /*
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <errno.h>
#include "../perf.h"
#include "util.h"
#include "trace-eve... |
google | android | cgroup | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/cgroup.c | 3,176 | utf_8 | e9a43ad3f548e4059fe6e348c68baf35 | #include "util.h"
#include "../perf.h"
#include "parse-options.h"
#include "evsel.h"
#include "cgroup.h"
#include "evlist.h"
int nr_cgroups;
static int
cgroupfs_find_mountpoint(char *buf, size_t maxlen)
{
FILE *fp;
char mountpoint[PATH_MAX + 1], tokens[PATH_MAX + 1], type[PATH_MAX + 1];
char *token, *saved_ptr = N... |
google | android | zlib | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/zlib.c | 1,371 | utf_8 | fb7f01ca243c3a341884606261b94a2f | #include <stdio.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/mman.h>
#include <zlib.h>
#include "util/util.h"
#include "util/debug.h"
#define CHUNK_SIZE 16384
int gzip_decompress_to_file(const char *input, int output_fd)
{
int ret = Z_STREAM_ERROR;
int input_fd;
void *ptr;
int len;
struct stat s... |
google | android | exec_cmd | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/exec_cmd.c | 2,782 | utf_8 | a1f608c75c66822e6860e954649bcd34 | #include "cache.h"
#include "exec_cmd.h"
#include "quote.h"
#include <string.h>
#define MAX_ARGS 32
static const char *argv_exec_path;
static const char *argv0_path;
const char *system_path(const char *path)
{
static const char *prefix = PREFIX;
struct strbuf d = STRBUF_INIT;
if (is_absolute_path(path))
retur... |
google | android | map | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/map.c | 19,190 | utf_8 | fd8a45dd483d4abf93c673ac89e21146 | #include "symbol.h"
#include <errno.h>
#include <inttypes.h>
#include <limits.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <unistd.h>
#include "map.h"
#include "thread.h"
#include "strlist.h"
#include "vdso.h"
#include "build-id.h"
#include "util.h"
#include "debug.h"
#include "machine.h"
#inc... |
google | android | python | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/python.c | 31,035 | utf_8 | a4625d145624661fd0595826fbbb7d71 | #include <Python.h>
#include <structmember.h>
#include <inttypes.h>
#include <poll.h>
#include "evlist.h"
#include "evsel.h"
#include "event.h"
#include "cpumap.h"
#include "thread_map.h"
/*
* Support debug printing even though util/debug.c is not linked. That means
* implementing 'verbose' and 'eprintf'.
*/
int ve... |
google | android | env | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/env.c | 1,854 | utf_8 | a5282cf438e00577ea072a8b3c59cf8e | #include "cpumap.h"
#include "env.h"
#include "util.h"
struct perf_env perf_env;
void perf_env__exit(struct perf_env *env)
{
zfree(&env->hostname);
zfree(&env->os_release);
zfree(&env->version);
zfree(&env->arch);
zfree(&env->cpu_desc);
zfree(&env->cpuid);
zfree(&env->cmdline);
zfree(&env->cmdline_argv);
zfr... |
google | android | bpf-loader | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/bpf-loader.c | 10,151 | utf_8 | 357da1ee2a4e6db8ffdb7d9ffc8828a5 | /*
* bpf-loader.c
*
*/
#include <bpf/libbpf.h>
#include <linux/err.h>
#include "perf.h"
#include "debug.h"
#include "bpf-loader.h"
#include "probe-event.h"
#include "probe-finder.h" // for MAX_PROBES
#include "llvm-utils.h"
#define DEFINE_PRINT_FN(name, level) \
static int libbpf_##name(const char *fmt, ...) \
{ ... |
google | android | color | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/color.c | 4,739 | utf_8 | e921bc6a4769f362b3aa7a410b8454be | #include <linux/kernel.h>
#include "cache.h"
#include "color.h"
#include <math.h>
int perf_use_color_default = -1;
int perf_config_colorbool(const char *var, const char *value, int stdout_is_tty)
{
if (value) {
if (!strcasecmp(value, "never"))
return 0;
if (!strcasecmp(value, "always"))
return 1;
if (!st... |
google | android | build-id | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/build-id.c | 11,960 | utf_8 | 7aaecfe3b65900a4907e1ae8c65c6e38 | /*
* build-id.c
*
* build-id support
*
*/
#include "util.h"
#include <stdio.h>
#include "build-id.h"
#include "event.h"
#include "symbol.h"
#include <linux/kernel.h>
#include "debug.h"
#include "session.h"
#include "tool.h"
#include "header.h"
#include "vdso.h"
static bool no_buildid_cache;
int build_id__mark_dso_... |
google | android | symbol-minimal | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/symbol-minimal.c | 7,333 | utf_8 | 6388f777c0b2a87f3f2e31d4a19d782e | #include "symbol.h"
#include "util.h"
#include <stdio.h>
#include <fcntl.h>
#include <string.h>
#include <byteswap.h>
#include <sys/stat.h>
static bool check_need_swap(int file_endian)
{
const int data = 1;
u8 *check = (u8 *)&data;
int host_endian;
if (check[0] == 1)
host_endian = ELFDATA2LSB;
else
host_en... |
google | android | wrapper | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/wrapper.c | 817 | utf_8 | 13e28fea26dc920b89233b90d2afb88a | /*
* Various trivial helper wrappers around standard functions
*/
#include "cache.h"
/*
* There's no pack memory to release - but stay close to the Git
* version so wrap this away:
*/
static inline void release_pack_memory(size_t size __maybe_unused,
int flag __maybe_unused)
{
}
char *xstrdup(const ch... |
google | android | stat-shadow | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/stat-shadow.c | 14,263 | utf_8 | 8dffa274f144585546c355117bae99b9 | #include <stdio.h>
#include "evsel.h"
#include "stat.h"
#include "color.h"
enum {
CTX_BIT_USER = 1 << 0,
CTX_BIT_KERNEL = 1 << 1,
CTX_BIT_HV = 1 << 2,
CTX_BIT_HOST = 1 << 3,
CTX_BIT_IDLE = 1 << 4,
CTX_BIT_MAX = 1 << 5,
};
#define NUM_CTX CTX_BIT_MAX
static struct stats runtime_nsecs_stats[MAX_NR_CPUS];
static str... |
google | android | pager | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/pager.c | 1,894 | utf_8 | f06e72ed090970bf02fd0bb5ab4b97b4 | #include "cache.h"
#include "run-command.h"
#include "sigchain.h"
/*
* This is split up from the rest of git so that we can do
* something different on Windows.
*/
static int spawned_pager;
static void pager_preexec(void)
{
/*
* Work around bug in "less" by not starting it until we
* have real input
*/
fd... |
google | android | session | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/session.c | 56,145 | utf_8 | eeba249c08089bc8767697c9d86554ba | #include <linux/kernel.h>
#include <traceevent/event-parse.h>
#include <byteswap.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/mman.h>
#include "evlist.h"
#include "evsel.h"
#include "session.h"
#include "tool.h"
#include "sort.h"
#include "util.h"
#include "cpumap.h"
#include "perf_regs.h"
#include "asm/... |
google | android | values | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/values.c | 6,707 | utf_8 | 4e221397c5a9ba9119a68127f654dc96 | #include <stdlib.h>
#include "util.h"
#include "values.h"
void perf_read_values_init(struct perf_read_values *values)
{
values->threads_max = 16;
values->pid = malloc(values->threads_max * sizeof(*values->pid));
values->tid = malloc(values->threads_max * sizeof(*values->tid));
values->value = malloc(values->threa... |
google | android | xyarray | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/xyarray.c | 513 | utf_8 | d6b390c0df330c2850271c671f7d7a41 | #include "xyarray.h"
#include "util.h"
struct xyarray *xyarray__new(int xlen, int ylen, size_t entry_size)
{
size_t row_size = ylen * entry_size;
struct xyarray *xy = zalloc(sizeof(*xy) + xlen * row_size);
if (xy != NULL) {
xy->entry_size = entry_size;
xy->row_size = row_size;
xy->entries = xlen * ylen;... |
google | android | svghelper | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/svghelper.c | 23,037 | utf_8 | f0e75582bbaeaaf5a60cbfb5dbc8522c | /*
* svghelper.c - helper functions for outputting svg
*
*/
#include <inttypes.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <linux/bitmap.h>
#include "perf.h"
#include "svghelper.h"
#include "util.h"
#include "cpumap.h"
static u64 first_time, last_time;
static u64 turbo_... |
google | android | strfilter | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/strfilter.c | 6,281 | utf_8 | 3f8e40d3ca2f06dc52ece7a4b5d8940c | #include "util.h"
#include "string.h"
#include "strfilter.h"
/* Operators */
static const char *OP_and = "&"; /* Logical AND */
static const char *OP_or = "|"; /* Logical OR */
static const char *OP_not = "!"; /* Logical NOT */
static void strfilter_node__delete(struct strfilter_node *node)
{
if (node) {
if (node->p... |
google | android | help | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/help.c | 7,970 | utf_8 | 31e379244f563429eea585ae42d804c4 | #include "cache.h"
#include "../builtin.h"
#include "exec_cmd.h"
#include "levenshtein.h"
#include "help.h"
#include <termios.h>
void add_cmdname(struct cmdnames *cmds, const char *name, size_t len)
{
struct cmdname *ent = malloc(sizeof(*ent) + len + 1);
ent->len = len;
memcpy(ent->name, name, len);
ent->name[len... |
google | android | data | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/data.c | 2,611 | utf_8 | 60e9cf6e47e8857d9f655ef11516df57 | #include <linux/compiler.h>
#include <linux/kernel.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <string.h>
#include "data.h"
#include "util.h"
#include "debug.h"
static bool check_pipe(struct perf_data_file *file)
{
struct stat st;
bool is_pipe = false;
int fd = perf_data_file__is_r... |
google | android | callchain | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/callchain.c | 19,228 | utf_8 | 7951bb02a385410481b1ce0e948a0628 | /*
*
* Handle the callchains from the stream in an ad-hoc radix tree and then
* sort them in an rbtree.
*
* Using a radix for code path provides a fast retrieval and factorizes
* memory use. Also that lets us use the paths in a hierarchical graph view.
*
*/
#include <stdlib.h>
#include <stdio.h>
#include <stdbo... |
google | android | dso | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/dso.c | 31,678 | utf_8 | 8f32d37f743d9a5deda5d117f7f4ecc1 | #include <asm/bug.h>
#include <sys/time.h>
#include <sys/resource.h>
#include "symbol.h"
#include "dso.h"
#include "machine.h"
#include "auxtrace.h"
#include "util.h"
#include "debug.h"
char dso__symtab_origin(const struct dso *dso)
{
static const char origin[] = {
[DSO_BINARY_TYPE__KALLSYMS] = 'k',
[DSO_BINARY_... |
google | android | event | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/event.c | 29,031 | utf_8 | 5a9822183c184554a4da442dcb2fbd29 | #include <linux/types.h>
#include <sys/mman.h>
#include "event.h"
#include "debug.h"
#include "hist.h"
#include "machine.h"
#include "sort.h"
#include "string.h"
#include "strlist.h"
#include "thread.h"
#include "thread_map.h"
#include "symbol/kallsyms.h"
static const char *perf_event__names[] = {
[0] = "TOTAL",
... |
google | android | pstack | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/pstack.c | 1,639 | utf_8 | fffd04a558e9f853610aef88e7985ee3 | /*
* Simple pointer stack
*
*/
#include "util.h"
#include "pstack.h"
#include "debug.h"
#include <linux/kernel.h>
#include <stdlib.h>
struct pstack {
unsigned short top;
unsigned short max_nr_entries;
void *entries[0];
};
struct pstack *pstack__new(unsigned short max_nr_entries)
{
struct pstack *pstack = zalloc... |
google | android | trace-event-read | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/trace-event-read.c | 8,160 | utf_8 | b457d0d31f229c85fe327f442bce646f | /*
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/
#include <dirent.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <s... |
google | android | trace-event-python | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/scripting-engines/trace-event-python.c | 31,243 | utf_8 | 0e72406ca7724c25b78832764913d17c | /*
* trace-event-python. Feed trace events to an embedded Python interpreter.
*
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
#include <Python.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdbool.h>
#include <errno.h>
#include <linux/bitmap.h>
#includ... |
google | android | trace-event-perl | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/scripting-engines/trace-event-perl.c | 15,764 | utf_8 | 4d1223f178fbb84ac7d30b28e73449ff | /*
* trace-event-perl. Feed perf script events to an embedded Perl interpreter.
*
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <errno.h>
#include <linux/bitmap.h>
#include "../util.h"
#inclu... |
google | android | intel-pt-insn-decoder | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/intel-pt-insn-decoder.c | 6,172 | utf_8 | 06359b6b168b957c5fe2ab11c5e4616a | /*
* intel_pt_insn_decoder.c: Intel Processor Trace support
* more details.
*
*/
#include <stdio.h>
#include <string.h>
#include <endian.h>
#include <byteswap.h>
#include "event.h"
#include "insn.h"
#include "inat.c"
#include "insn.c"
#include "intel-pt-insn-decoder.h"
/* Based on branch_type() from perf_event_inte... |
google | android | inat | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/inat.c | 2,621 | utf_8 | ea396c810c46d3a6edc5a229a80ca455 | /*
* x86 instruction attribute tables
*
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#include "insn.h"
/* Attribute tables are generated from opcode map */
#include "inat-tables.c"
/* Attribute search APIs */
insn_attr_t inat_get_opcode_attribute(insn_byte_t opcode)
{
return i... |
google | android | intel-pt-decoder | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c | 57,244 | utf_8 | 7c4f449ad74351611ae04ed12eeda4e0 | /*
* intel_pt_decoder.c: Intel Processor Trace support
* more details.
*
*/
#ifndef _GNU_SOURCE
#define _GNU_SOURCE
#endif
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#include <errno.h>
#include <stdint.h>
#include <inttypes.h>
#include "../cache.h"
#include "../util.h"
#include "intel-pt-insn-deco... |
google | android | intel-pt-pkt-decoder | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/intel-pt-pkt-decoder.c | 11,656 | utf_8 | b7f9125b9bf9c2155ad1da9c2b433d5a | /*
* intel_pt_pkt_decoder.c: Intel Processor Trace support
* more details.
*
*/
#include <stdio.h>
#include <string.h>
#include <endian.h>
#include <byteswap.h>
#include "intel-pt-pkt-decoder.h"
#define BIT(n) (1 << (n))
#define BIT63 ((uint64_t)1 << 63)
#define NR_FLAG BIT63
#if __BYTE_ORDER == __BIG_ENDIAN
#de... |
google | android | insn | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/insn.c | 15,094 | utf_8 | 2cceeafa32f9b435de01c0dafb6811be | /*
* x86 instruction analysis
*
*/
#ifdef __KERNEL__
#include <linux/string.h>
#else
#include <string.h>
#endif
#include "inat.h"
#include "insn.h"
/* Verify next sizeof(t) bytes can be on the same instruction */
#define validate_next(t, insn, n) \
((insn)->next_byte + sizeof(t) + n <= (insn)->end_kaddr)
#define __... |
google | android | intel-pt-log | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/util/intel-pt-decoder/intel-pt-log.c | 3,248 | utf_8 | 2968ef7dbb3ac5bc0d43deeb8657055d | /*
* intel_pt_log.c: Intel Processor Trace support
* more details.
*
*/
#include <stdio.h>
#include <stdint.h>
#include <inttypes.h>
#include <stdarg.h>
#include <stdbool.h>
#include <string.h>
#include "intel-pt-log.h"
#include "intel-pt-insn-decoder.h"
#include "intel-pt-pkt-decoder.h"
#define MAX_LOG_NAME 256
st... |
google | android | util | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/util.c | 1,588 | utf_8 | ea9ccdf1bbd5cd23cc3b677641b07fb0 | #include "util.h"
#include "../debug.h"
/*
* Default error logging functions
*/
static int perf_stdio__error(const char *format, va_list args)
{
fprintf(stderr, "Error:\n");
vfprintf(stderr, format, args);
return 0;
}
static int perf_stdio__warning(const char *format, va_list args)
{
fprintf(stderr, "Warning:\n")... |
google | android | progress | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/progress.c | 704 | utf_8 | 819df0cf29b7c206536df1495cf3392f | #include "../cache.h"
#include "progress.h"
static void null_progress__update(struct ui_progress *p __maybe_unused)
{
}
static struct ui_progress_ops null_progress__ops =
{
.update = null_progress__update,
};
struct ui_progress_ops *ui_progress__ops = &null_progress__ops;
void ui_progress__update(struct ui_progres... |
google | android | helpline | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/helpline.c | 1,192 | utf_8 | f91306dabc32b3e37951d083090b810b | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "../debug.h"
#include "helpline.h"
#include "ui.h"
char ui_helpline__current[512];
static void nop_helpline__pop(void)
{
}
static void nop_helpline__push(const char *msg __maybe_unused)
{
}
static int nop_helpline__show(const char *fmt __maybe_unu... |
google | android | hist | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/hist.c | 16,669 | utf_8 | 2310285415f9af8c603cf08084ffe704 | #include <math.h>
#include <linux/compiler.h>
#include "../util/hist.h"
#include "../util/util.h"
#include "../util/sort.h"
#include "../util/evsel.h"
/* hist period print (hpp) functions */
#define hpp__call_print_fn(hpp, fn, fmt, ...) \
({ \
int __ret = fn(hpp, fmt, ##__VA_ARGS__); \
advance_hpp(hpp, _... |
google | android | setup | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/setup.c | 1,965 | utf_8 | 3cd5b562a5fe6edd30f922ff5eb1b7cd | #include <pthread.h>
#include <dlfcn.h>
#include "../util/cache.h"
#include "../util/debug.h"
#include "../util/hist.h"
pthread_mutex_t ui__lock = PTHREAD_MUTEX_INITIALIZER;
void *perf_gtk_handle;
#ifdef HAVE_GTK2_SUPPORT
static int setup_gtk_browser(void)
{
int (*perf_ui_init)(void);
if (perf_gtk_handle)
retur... |
google | android | browser | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browser.c | 16,697 | utf_8 | 252f3680cb61afd2beb5477853330608 | #include "../util.h"
#include "../cache.h"
#include "../../perf.h"
#include "libslang.h"
#include "ui.h"
#include "util.h"
#include <linux/compiler.h>
#include <linux/list.h>
#include <linux/rbtree.h>
#include <stdlib.h>
#include <sys/ttydefaults.h>
#include "browser.h"
#include "helpline.h"
#include "keysyms.h"
#inclu... |
google | android | hist | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/stdio/hist.c | 11,746 | utf_8 | a59ce3726f509f23cc4eb8b324d7d5e6 | #include <stdio.h>
#include "../../util/util.h"
#include "../../util/hist.h"
#include "../../util/sort.h"
#include "../../util/evsel.h"
static size_t callchain__fprintf_left_margin(FILE *fp, int left_margin)
{
int i;
int ret = fprintf(fp, " ");
for (i = 0; i < left_margin; i++)
ret += fprintf(fp, " ... |
google | android | scripts | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browsers/scripts.c | 4,260 | utf_8 | 3a7844ec0cc8cf281dcf59d1103076f4 | #include <elf.h>
#include <inttypes.h>
#include <sys/ttydefaults.h>
#include <string.h>
#include "../../util/sort.h"
#include "../../util/util.h"
#include "../../util/hist.h"
#include "../../util/debug.h"
#include "../../util/symbol.h"
#include "../browser.h"
#include "../helpline.h"
#include "../libslang.h"
/* 2048 l... |
google | android | header | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browsers/header.c | 2,583 | utf_8 | f702acf5d73cbe2cb7f6e5e78cb862d7 | #include "util/cache.h"
#include "util/debug.h"
#include "ui/browser.h"
#include "ui/keysyms.h"
#include "ui/ui.h"
#include "ui/util.h"
#include "ui/libslang.h"
#include "util/header.h"
#include "util/session.h"
static void ui_browser__argv_write(struct ui_browser *browser,
void *entry, int row)
{
char **arg =... |
google | android | annotate | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browsers/annotate.c | 30,657 | utf_8 | 633727d3babad2a9d723c88ce8a79565 | #include "../../util/util.h"
#include "../browser.h"
#include "../helpline.h"
#include "../ui.h"
#include "../util.h"
#include "../../util/annotate.h"
#include "../../util/hist.h"
#include "../../util/sort.h"
#include "../../util/symbol.h"
#include "../../util/evsel.h"
#include <pthread.h>
struct disasm_line_samples {
... |
google | android | hists | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browsers/hists.c | 59,333 | utf_8 | f96b52595717068a358e0faffbdc26ef | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <linux/rbtree.h>
#include "../../util/evsel.h"
#include "../../util/evlist.h"
#include "../../util/hist.h"
#include "../../util/pstack.h"
#include "../../util/sort.h"
#include "../../util/util.h"
#include "../../util/top.h"
#include "../../arch/common... |
google | android | map | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/browsers/map.c | 3,276 | utf_8 | fa38872500618bd5a3fc8697d080f833 | #include <elf.h>
#include <inttypes.h>
#include <sys/ttydefaults.h>
#include <string.h>
#include <linux/bitops.h>
#include "../../util/util.h"
#include "../../util/debug.h"
#include "../../util/symbol.h"
#include "../browser.h"
#include "../helpline.h"
#include "../keysyms.h"
#include "map.h"
struct map_browser {
str... |
google | android | util | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/tui/util.c | 5,276 | utf_8 | c9e4e1b9b49b1f1ce917a648e1581030 | #include "../../util/util.h"
#include <signal.h>
#include <stdbool.h>
#include <string.h>
#include <sys/ttydefaults.h>
#include "../../util/cache.h"
#include "../../util/debug.h"
#include "../browser.h"
#include "../keysyms.h"
#include "../helpline.h"
#include "../ui.h"
#include "../util.h"
#include "../libslang.h"
s... |
google | android | progress | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/tui/progress.c | 1,366 | utf_8 | abf65dc9071c3d3f3114b3d6cc0346d0 | #include "../cache.h"
#include "../progress.h"
#include "../libslang.h"
#include "../ui.h"
#include "tui.h"
#include "../browser.h"
static void tui_progress__update(struct ui_progress *p)
{
int bar, y;
/*
* FIXME: We should have a per UI backend way of showing progress,
* stdio will just show a percentage as NN%... |
google | android | helpline | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/tui/helpline.c | 1,259 | utf_8 | 97fcd20291cda867eb61b30219175c5a | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pthread.h>
#include "../../util/debug.h"
#include "../helpline.h"
#include "../ui.h"
#include "../libslang.h"
char ui_helpline__last_msg[1024];
bool tui_helpline__set;
static void tui_helpline__pop(void)
{
}
static void tui_helpline__push(const ch... |
google | android | setup | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/tui/setup.c | 3,118 | utf_8 | 60be1c5118d99ca6b37eedb92c9dbbd9 | #include <signal.h>
#include <stdbool.h>
#ifdef HAVE_BACKTRACE_SUPPORT
#include <execinfo.h>
#endif
#include "../../util/cache.h"
#include "../../util/debug.h"
#include "../browser.h"
#include "../helpline.h"
#include "../ui.h"
#include "../util.h"
#include "../libslang.h"
#include "../keysyms.h"
#include "tui.h"
sta... |
google | android | annotate | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/annotate.c | 6,004 | utf_8 | 59f667053e7b0e2e8563731a3772759f | #include "gtk.h"
#include "util/debug.h"
#include "util/annotate.h"
#include "util/evsel.h"
#include "ui/helpline.h"
enum {
ANN_COL__PERCENT,
ANN_COL__OFFSET,
ANN_COL__LINE,
MAX_ANN_COLS
};
static const char *const col_names[] = {
"Overhead",
"Offset",
"Line"
};
static int perf_gtk__get_percent(char *buf, s... |
google | android | util | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/util.c | 2,347 | utf_8 | 9dc609c477e7a271d107e59a1c61dc73 | #include "../util.h"
#include "../../util/debug.h"
#include "gtk.h"
#include <string.h>
struct perf_gtk_context *pgctx;
struct perf_gtk_context *perf_gtk__activate_context(GtkWidget *window)
{
struct perf_gtk_context *ctx;
ctx = malloc(sizeof(*pgctx));
if (ctx)
ctx->main_window = window;
return ctx;
}
int ... |
google | android | progress | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/progress.c | 1,528 | utf_8 | 69cd8b19e70fc7ca3aa349d5a38e5fad | #include <inttypes.h>
#include "gtk.h"
#include "../progress.h"
#include "util.h"
static GtkWidget *dialog;
static GtkWidget *progress;
static void gtk_ui_progress__update(struct ui_progress *p)
{
double fraction = p->total ? 1.0 * p->curr / p->total : 0.0;
char buf[1024];
if (dialog == NULL) {
GtkWidget *vbox... |
google | android | helpline | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/helpline.c | 1,159 | utf_8 | 00b405210ace3439c5523c6d13267cc4 | #include <stdio.h>
#include <string.h>
#include "gtk.h"
#include "../ui.h"
#include "../helpline.h"
#include "../../util/debug.h"
static void gtk_helpline_pop(void)
{
if (!perf_gtk__is_active_context(pgctx))
return;
gtk_statusbar_pop(GTK_STATUSBAR(pgctx->statbar),
pgctx->statbar_ctx_id);
}
static void gtk_... |
google | android | setup | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/setup.c | 483 | utf_8 | d7240959e3800fb984883df80f41bde3 | #include "gtk.h"
#include "../../util/cache.h"
#include "../../util/debug.h"
extern struct perf_error_ops perf_gtk_eops;
int perf_gtk__init(void)
{
perf_error__register(&perf_gtk_eops);
perf_gtk__init_helpline();
gtk_ui_progress__init();
perf_gtk__init_hpp();
return gtk_init_check(NULL, NULL) ? 0 : -1;
}
void ... |
google | android | hists | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/hists.c | 8,975 | utf_8 | ad5148376f40bb136cd2ff1c50d65084 | #include "../evlist.h"
#include "../cache.h"
#include "../evsel.h"
#include "../sort.h"
#include "../hist.h"
#include "../helpline.h"
#include "gtk.h"
#define MAX_COLUMNS 32
static int __percent_color_snprintf(struct perf_hpp *hpp, const char *fmt, ...)
{
int ret = 0;
int len;
va_list args;
double percent;
con... |
google | android | browser | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/ui/gtk/browser.c | 1,810 | utf_8 | 22606e366277199d98fe8702ceed8691 | #include "../evlist.h"
#include "../cache.h"
#include "../evsel.h"
#include "../sort.h"
#include "../hist.h"
#include "../helpline.h"
#include "gtk.h"
#include <signal.h>
void perf_gtk__signal(int sig)
{
perf_gtk__exit(false);
psignal(sig, "perf");
}
void perf_gtk__resize_window(GtkWidget *window)
{
GdkRectangle ... |
google | android | thread-mg-share | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/thread-mg-share.c | 2,752 | utf_8 | 470800b0016fbc9d7bef8e00b129517d | #include "tests.h"
#include "machine.h"
#include "thread.h"
#include "map.h"
#include "debug.h"
int test__thread_mg_share(void)
{
struct machines machines;
struct machine *machine;
/* thread group */
struct thread *leader;
struct thread *t1, *t2, *t3;
struct map_groups *mg;
/* other process */
struct thread ... |
google | android | evsel-tp-sched | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/evsel-tp-sched.c | 2,028 | utf_8 | 1d3e5cd8bf94f8d4b65797c3ffc7e3bd | #include <linux/err.h>
#include <traceevent/event-parse.h>
#include "evsel.h"
#include "tests.h"
#include "debug.h"
static int perf_evsel__test_field(struct perf_evsel *evsel, const char *name,
int size, bool should_be_signed)
{
struct format_field *field = perf_evsel__field(evsel, name);
int is_signed;
int r... |
google | android | kmod-path | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/kmod-path.c | 6,732 | utf_8 | eeb3dcd9eec85925249d1e1d2c5eef74 | #include <stdbool.h>
#include "tests.h"
#include "dso.h"
#include "debug.h"
static int test(const char *path, bool alloc_name, bool alloc_ext,
bool kmod, bool comp, const char *name, const char *ext)
{
struct kmod_path m;
memset(&m, 0x0, sizeof(m));
TEST_ASSERT_VAL("kmod_path__parse",
!__kmod_path__parse(&m,... |
google | android | code-reading | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/code-reading.c | 13,332 | utf_8 | 1fb167306f09c8c280318c98c33f2d07 | #include <linux/types.h>
#include <stdlib.h>
#include <unistd.h>
#include <stdio.h>
#include <ctype.h>
#include <string.h>
#include "parse-events.h"
#include "evlist.h"
#include "evsel.h"
#include "thread_map.h"
#include "cpumap.h"
#include "machine.h"
#include "event.h"
#include "thread.h"
#include "tests.h"
#defin... |
google | android | keep-tracking | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/keep-tracking.c | 3,379 | utf_8 | c4f3e3ac52de6b36dd6e7ac389496a98 | #include <linux/types.h>
#include <unistd.h>
#include <sys/prctl.h>
#include "parse-events.h"
#include "evlist.h"
#include "evsel.h"
#include "thread_map.h"
#include "cpumap.h"
#include "tests.h"
#define CHECK__(x) { \
while ((x) < 0) { \
pr_debug(#x " failed!\n"); \
goto out_err; \
} \
}
#define CHECK... |
google | android | sample-parsing | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/sample-parsing.c | 8,202 | utf_8 | 7daee29876388a93f42830cfad4e7464 | #include <stdbool.h>
#include <linux/types.h>
#include "util.h"
#include "event.h"
#include "evsel.h"
#include "debug.h"
#include "tests.h"
#define COMP(m) do { \
if (s1->m != s2->m) { \
pr_debug("Samples differ at '"#m"'\n"); \
return false; \
} \
} while (0)
#define MCOMP(m) do { \
if (m... |
google | android | bp_signal | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/bp_signal.c | 4,345 | utf_8 | e6a05aa52c9239fa88255b2e2d85944c | /*
* Inspired by breakpoint overflow test done by
* (git://github.com/deater/perf_event_tests)
*/
/*
* Powerpc needs __SANE_USERSPACE_TYPES__ before <linux/types.h> to select
* 'int-ll64.h' and avoid compile warnings when printing __u64 with %llu.
*/
#define __SANE_USERSPACE_TYPES__
#include <stdlib.h>
#include <... |
google | android | vmlinux-kallsyms | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/vmlinux-kallsyms.c | 6,487 | utf_8 | 6f9478eba6ed74ce54233d74f27d1911 | #include <linux/compiler.h>
#include <linux/rbtree.h>
#include <string.h>
#include "map.h"
#include "symbol.h"
#include "util.h"
#include "tests.h"
#include "debug.h"
#include "machine.h"
static int vmlinux_matches_kallsyms_filter(struct map *map __maybe_unused,
struct symbol *sym)
{
bool *visited = symbol__p... |
google | android | openat-syscall-tp-fields | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/openat-syscall-tp-fields.c | 2,612 | utf_8 | 7dcb9c750dd163c60714fd194e4792ae | #include <linux/err.h>
#include "perf.h"
#include "evlist.h"
#include "evsel.h"
#include "thread_map.h"
#include "tests.h"
#include "debug.h"
int test__syscall_openat_tp_fields(void)
{
struct record_opts opts = {
.target = {
.uid = UINT_MAX,
.uses_mmap = true,
},
.no_buffering = true,
.freq = 1,
... |
google | android | llvm | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/llvm.c | 3,805 | utf_8 | 47901ba3c4fb1376df1c1780d218eb2b | #include <stdio.h>
#include <bpf/libbpf.h>
#include <util/llvm-utils.h>
#include <util/cache.h>
#include "llvm.h"
#include "tests.h"
#include "debug.h"
static int perf_config_cb(const char *var, const char *val,
void *arg __maybe_unused)
{
return perf_default_config(var, val, arg);
}
#ifdef HAVE_LIBBPF_SUPPORT
... |
google | android | evsel-roundtrip-name | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/evsel-roundtrip-name.c | 2,604 | utf_8 | e1cccfe19c71dd5a9e5d827e4b175999 | #include "evlist.h"
#include "evsel.h"
#include "parse-events.h"
#include "tests.h"
#include "debug.h"
static int perf_evsel__roundtrip_cache_name_test(void)
{
char name[128];
int type, op, err = 0, ret = 0, i, idx;
struct perf_evsel *evsel;
struct perf_evlist *evlist = perf_evlist__new();
if (evlist == N... |
google | android | fdarray | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/fdarray.c | 4,363 | utf_8 | e28265339df47c75d0f3aa3bdfa584e5 | #include <api/fd/array.h>
#include "util/debug.h"
#include "tests/tests.h"
static void fdarray__init_revents(struct fdarray *fda, short revents)
{
int fd;
fda->nr = fda->nr_alloc;
for (fd = 0; fd < fda->nr; ++fd) {
fda->entries[fd].fd = fda->nr - fd;
fda->entries[fd].revents = revents;
}
}
static int fdarr... |
google | android | parse-events | .c | platform/hardware/bsp/kernel/intel/edison-v4.4/tools/perf/tests/parse-events.c | 63,499 | utf_8 | f08ac2beccc4ac7f69b1cf0be605764e | #include "parse-events.h"
#include "evsel.h"
#include "evlist.h"
#include <api/fs/fs.h>
#include "tests.h"
#include "debug.h"
#include "util.h"
#include <linux/hw_breakpoint.h>
#include <api/fs/fs.h>
#define PERF_TP_SAMPLE_TYPE (PERF_SAMPLE_RAW | PERF_SAMPLE_TIME | \
PERF_SAMPLE_CPU | PERF_SAMPLE_PERIOD)
static... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.