c2c_he 133 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 135 tools/perf/builtin-c2c.c c2c_he = zalloc(size + sizeof(*c2c_he)); c2c_he 136 tools/perf/builtin-c2c.c if (!c2c_he) c2c_he 139 tools/perf/builtin-c2c.c c2c_he->cpuset = bitmap_alloc(c2c.cpus_cnt); c2c_he 140 tools/perf/builtin-c2c.c if (!c2c_he->cpuset) c2c_he 143 tools/perf/builtin-c2c.c c2c_he->nodeset = bitmap_alloc(c2c.nodes_cnt); c2c_he 144 tools/perf/builtin-c2c.c if (!c2c_he->nodeset) c2c_he 147 tools/perf/builtin-c2c.c c2c_he->node_stats = zalloc(c2c.nodes_cnt * sizeof(*c2c_he->node_stats)); c2c_he 148 tools/perf/builtin-c2c.c if (!c2c_he->node_stats) c2c_he 151 tools/perf/builtin-c2c.c init_stats(&c2c_he->cstats.lcl_hitm); c2c_he 152 tools/perf/builtin-c2c.c init_stats(&c2c_he->cstats.rmt_hitm); c2c_he 153 tools/perf/builtin-c2c.c init_stats(&c2c_he->cstats.load); c2c_he 155 tools/perf/builtin-c2c.c return &c2c_he->he; c2c_he 160 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 162 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 163 tools/perf/builtin-c2c.c if (c2c_he->hists) { c2c_he 164 tools/perf/builtin-c2c.c hists__delete_entries(&c2c_he->hists->hists); c2c_he 165 tools/perf/builtin-c2c.c free(c2c_he->hists); c2c_he 168 tools/perf/builtin-c2c.c free(c2c_he->cpuset); c2c_he 169 tools/perf/builtin-c2c.c free(c2c_he->nodeset); c2c_he 170 tools/perf/builtin-c2c.c free(c2c_he->nodestr); c2c_he 171 tools/perf/builtin-c2c.c free(c2c_he->node_stats); c2c_he 172 tools/perf/builtin-c2c.c free(c2c_he); c2c_he 189 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 193 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 194 tools/perf/builtin-c2c.c if (c2c_he->hists) c2c_he 195 tools/perf/builtin-c2c.c return c2c_he->hists; c2c_he 197 tools/perf/builtin-c2c.c hists = c2c_he->hists = zalloc(sizeof(*hists)); c2c_he 210 tools/perf/builtin-c2c.c static void c2c_he__set_cpu(struct c2c_hist_entry *c2c_he, c2c_he 217 tools/perf/builtin-c2c.c set_bit(sample->cpu, c2c_he->cpuset); c2c_he 220 tools/perf/builtin-c2c.c static void c2c_he__set_node(struct c2c_hist_entry *c2c_he, c2c_he 226 tools/perf/builtin-c2c.c c2c_he->paddr_zero = true; c2c_he 234 tools/perf/builtin-c2c.c set_bit(node, c2c_he->nodeset); c2c_he 236 tools/perf/builtin-c2c.c if (c2c_he->paddr != sample->phys_addr) { c2c_he 237 tools/perf/builtin-c2c.c c2c_he->paddr_cnt++; c2c_he 238 tools/perf/builtin-c2c.c c2c_he->paddr = sample->phys_addr; c2c_he 242 tools/perf/builtin-c2c.c static void compute_stats(struct c2c_hist_entry *c2c_he, c2c_he 246 tools/perf/builtin-c2c.c struct compute_stats *cstats = &c2c_he->cstats; c2c_he 263 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 300 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 301 tools/perf/builtin-c2c.c c2c_add_stats(&c2c_he->stats, &stats); c2c_he 304 tools/perf/builtin-c2c.c c2c_he__set_cpu(c2c_he, sample); c2c_he 305 tools/perf/builtin-c2c.c c2c_he__set_node(c2c_he, sample); c2c_he 334 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 335 tools/perf/builtin-c2c.c c2c_add_stats(&c2c_he->stats, &stats); c2c_he 337 tools/perf/builtin-c2c.c c2c_add_stats(&c2c_he->node_stats[node], &stats); c2c_he 339 tools/perf/builtin-c2c.c compute_stats(c2c_he, &stats, sample->weight); c2c_he 341 tools/perf/builtin-c2c.c c2c_he__set_cpu(c2c_he, sample); c2c_he 342 tools/perf/builtin-c2c.c c2c_he__set_node(c2c_he, sample); c2c_he 509 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 512 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 513 tools/perf/builtin-c2c.c if (WARN_ON_ONCE(!c2c_he->nodestr)) c2c_he 516 tools/perf/builtin-c2c.c return scnprintf(hpp->buf, hpp->size, "%*s", width, c2c_he->nodestr); c2c_he 523 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 526 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 527 tools/perf/builtin-c2c.c return scnprintf(hpp->buf, hpp->size, "%*lu", width, c2c_he->paddr_cnt); c2c_he 582 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 586 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 587 tools/perf/builtin-c2c.c tot_hitm = c2c_he->stats.lcl_hitm + c2c_he->stats.rmt_hitm; c2c_he 615 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; \ c2c_he 618 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); \ c2c_he 620 tools/perf/builtin-c2c.c c2c_he->stats.__f); \ c2c_he 667 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 670 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 673 tools/perf/builtin-c2c.c llc_miss(&c2c_he->stats)); c2c_he 717 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 721 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 722 tools/perf/builtin-c2c.c tot_recs = total_records(&c2c_he->stats); c2c_he 768 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 772 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 773 tools/perf/builtin-c2c.c tot_recs = total_loads(&c2c_he->stats); c2c_he 802 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 806 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 807 tools/perf/builtin-c2c.c per = get_percent(c2c_he); c2c_he 816 tools/perf/builtin-c2c.c static double percent_hitm(struct c2c_hist_entry *c2c_he) c2c_he 824 tools/perf/builtin-c2c.c hists = container_of(c2c_he->he.hists, struct c2c_hists, hists); c2c_he 825 tools/perf/builtin-c2c.c stats = &c2c_he->stats; c2c_he 859 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 864 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 865 tools/perf/builtin-c2c.c per = percent_hitm(c2c_he); c2c_he 896 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 898 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 899 tools/perf/builtin-c2c.c return &c2c_he->stats; c2c_he 918 tools/perf/builtin-c2c.c static double percent_ ## __f(struct c2c_hist_entry *c2c_he) \ c2c_he 922 tools/perf/builtin-c2c.c hists = container_of(c2c_he->he.hists, struct c2c_hists, hists); \ c2c_he 923 tools/perf/builtin-c2c.c return percent(c2c_he->stats.__f, hists->stats.__f); \ c2c_he 1086 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1091 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1097 tools/perf/builtin-c2c.c bitmap_and(set, c2c_he->cpuset, c2c.nodes[node], c2c.cpus_cnt); c2c_he 1120 tools/perf/builtin-c2c.c struct c2c_stats *stats = &c2c_he->node_stats[node]; c2c_he 1126 tools/perf/builtin-c2c.c if (c2c_he->stats.__h> 0) { \ c2c_he 1128 tools/perf/builtin-c2c.c percent(stats->__h, c2c_he->stats.__h));\ c2c_he 1150 tools/perf/builtin-c2c.c if (c2c_he->stats.store > 0) { c2c_he 1152 tools/perf/builtin-c2c.c percent(stats->store, c2c_he->stats.store)); c2c_he 1195 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; \ c2c_he 1196 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); \ c2c_he 1197 tools/perf/builtin-c2c.c return mean_entry(fmt, hpp, he, avg_stats(&c2c_he->cstats.__val)); \ c2c_he 1208 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1212 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1214 tools/perf/builtin-c2c.c scnprintf(buf, 10, "%d", bitmap_weight(c2c_he->cpuset, c2c.cpus_cnt)); c2c_he 1222 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1226 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1228 tools/perf/builtin-c2c.c scnprintf(buf, 10, "%u", c2c_he->cacheline_idx); c2c_he 1896 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1902 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1906 tools/perf/builtin-c2c.c ld_dist = ((double)c2c_he->stats.__h / stats->__h); \ c2c_he 1933 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1936 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1937 tools/perf/builtin-c2c.c has_hitm = c2c.display == DISPLAY_TOT ? c2c_he->stats.tot_hitm : c2c_he 1938 tools/perf/builtin-c2c.c c2c.display == DISPLAY_LCL ? c2c_he->stats.lcl_hitm : c2c_he 1939 tools/perf/builtin-c2c.c c2c_he->stats.rmt_hitm; c2c_he 1940 tools/perf/builtin-c2c.c return has_hitm || c2c_he->stats.store; c2c_he 1943 tools/perf/builtin-c2c.c static void set_node_width(struct c2c_hist_entry *c2c_he, int len) c2c_he 1947 tools/perf/builtin-c2c.c dim = &c2c.hists == c2c_he->hists ? c2c_he 1954 tools/perf/builtin-c2c.c static int set_nodestr(struct c2c_hist_entry *c2c_he) c2c_he 1959 tools/perf/builtin-c2c.c if (c2c_he->nodestr) c2c_he 1962 tools/perf/builtin-c2c.c if (bitmap_weight(c2c_he->nodeset, c2c.nodes_cnt)) { c2c_he 1963 tools/perf/builtin-c2c.c len = bitmap_scnprintf(c2c_he->nodeset, c2c.nodes_cnt, c2c_he 1969 tools/perf/builtin-c2c.c set_node_width(c2c_he, len); c2c_he 1970 tools/perf/builtin-c2c.c c2c_he->nodestr = strdup(buf); c2c_he 1971 tools/perf/builtin-c2c.c return c2c_he->nodestr ? 0 : -ENOMEM; c2c_he 1974 tools/perf/builtin-c2c.c static void calc_width(struct c2c_hist_entry *c2c_he) c2c_he 1978 tools/perf/builtin-c2c.c c2c_hists = container_of(c2c_he->he.hists, struct c2c_hists, hists); c2c_he 1979 tools/perf/builtin-c2c.c hists__calc_col_len(&c2c_hists->hists, &c2c_he->he); c2c_he 1980 tools/perf/builtin-c2c.c set_nodestr(c2c_he); c2c_he 1985 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 1987 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 1992 tools/perf/builtin-c2c.c calc_width(c2c_he); c2c_he 2002 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 2006 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 2007 tools/perf/builtin-c2c.c c2c_hists = c2c_he->hists; c2c_he 2012 tools/perf/builtin-c2c.c c2c_he->cacheline_idx = idx++; c2c_he 2013 tools/perf/builtin-c2c.c calc_width(c2c_he); c2c_he 2093 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 2094 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 2096 tools/perf/builtin-c2c.c if (HAS_HITMS(c2c_he)) { c2c_he 2098 tools/perf/builtin-c2c.c c2c_add_stats(&c2c.hitm_stats, &c2c_he->stats); c2c_he 2237 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 2242 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 2243 tools/perf/builtin-c2c.c print_cacheline(c2c_he->hists, he, &hpp_list, out); c2c_he 2356 tools/perf/builtin-c2c.c struct c2c_hist_entry *c2c_he; c2c_he 2373 tools/perf/builtin-c2c.c c2c_he = container_of(he, struct c2c_hist_entry, he); c2c_he 2374 tools/perf/builtin-c2c.c c2c_hists = c2c_he->hists;