perf tools: Configurable per thread proc map processing time out
The time out to limit the individual proc map processing was hard code to 500ms. This patch introduce a new option --proc-map-timeout to make the time limit configurable. Signed-off-by: Kan Liang <kan.liang@intel.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: David Ahern <dsahern@gmail.com> Cc: Ying Huang <ying.huang@intel.com> Link: http://lkml.kernel.org/r/1434549071-25611-2-git-send-email-kan.liang@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:

committed by
Arnaldo Carvalho de Melo

parent
930e6fcd2b
commit
9d9cad763c
@@ -451,7 +451,7 @@ static int do_test_code_reading(bool try_kcore)
|
||||
}
|
||||
|
||||
ret = perf_event__synthesize_thread_map(NULL, threads,
|
||||
perf_event__process, machine, false);
|
||||
perf_event__process, machine, false, 500);
|
||||
if (ret < 0) {
|
||||
pr_debug("perf_event__synthesize_thread_map failed\n");
|
||||
goto out_err;
|
||||
|
@@ -28,7 +28,7 @@ static int init_live_machine(struct machine *machine)
|
||||
pid_t pid = getpid();
|
||||
|
||||
return perf_event__synthesize_mmap_events(NULL, &event, pid, pid,
|
||||
mmap_handler, machine, true);
|
||||
mmap_handler, machine, true, 500);
|
||||
}
|
||||
|
||||
#define MAX_STACK 8
|
||||
|
@@ -129,7 +129,7 @@ static int synth_all(struct machine *machine)
|
||||
{
|
||||
return perf_event__synthesize_threads(NULL,
|
||||
perf_event__process,
|
||||
machine, 0);
|
||||
machine, 0, 500);
|
||||
}
|
||||
|
||||
static int synth_process(struct machine *machine)
|
||||
@@ -141,7 +141,7 @@ static int synth_process(struct machine *machine)
|
||||
|
||||
err = perf_event__synthesize_thread_map(NULL, map,
|
||||
perf_event__process,
|
||||
machine, 0);
|
||||
machine, 0, 500);
|
||||
|
||||
thread_map__delete(map);
|
||||
return err;
|
||||
|
Reference in New Issue
Block a user