From: Ingo Molnar Date: Mon, 25 May 2009 07:59:50 +0000 (+0200) Subject: perf_counter tools: increase limits, fix X-Git-Tag: Ubuntu-5.4-5.4.0-11.14~30198^2~235 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=85a9f9200226ddffc2ea50dae6a8df04c033ecd4;p=mirror_ubuntu-focal-kernel.git perf_counter tools: increase limits, fix NR_CPUS and NR_COUNTERS goes up quadratic ... 1024x4096 was far too ambitious upper limit - go for 256x256 which is still plenty. [ Impact: reduce perf tool memory consumption ] Cc: Peter Zijlstra Cc: Paul Mackerras Cc: Corey Ashford Cc: Arnaldo Carvalho de Melo Cc: John Kacur Cc: Mike Galbraith LKML-Reference: Signed-off-by: Ingo Molnar --- diff --git a/Documentation/perf_counter/perf.h b/Documentation/perf_counter/perf.h index a517683fc661..5a2520bb7e55 100644 --- a/Documentation/perf_counter/perf.h +++ b/Documentation/perf_counter/perf.h @@ -61,8 +61,8 @@ sys_perf_counter_open(struct perf_counter_hw_event *hw_event_uptr, group_fd, flags); } -#define MAX_COUNTERS 1024 -#define MAX_NR_CPUS 4096 +#define MAX_COUNTERS 256 +#define MAX_NR_CPUS 256 #define EID(type, id) (((__u64)(type) << PERF_COUNTER_TYPE_SHIFT) | (id))