perf record: Enable the enable_on_exec flag if record forks the target
authorEric B Munson <ebmunson@us.ibm.com>
Mon, 15 Mar 2010 14:46:57 +0000 (11:46 -0300)
committerIngo Molnar <mingo@elte.hu>
Mon, 15 Mar 2010 15:08:22 +0000 (16:08 +0100)
commitbedbfdea31daf3880745001d56450c683959ee7e
treef039ee87fc0c76805f5f42c46b25ee732b8d6e0c
parente4495262826d1eabca3529fa6ac22394eb348132
perf record: Enable the enable_on_exec flag if record forks the target

When forking its target, perf record can capture data from
before the target application is started.  Perf stat uses the
enable_on_exec flag in the event attributes to keep from
displaying events from before the target program starts, this
patch adds the same functionality to perf record when it is will
fork the target process.

Signed-off-by: Eric B Munson <ebmunson@us.ibm.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
LKML-Reference: <1268664418-28328-1-git-send-email-acme@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
tools/perf/builtin-record.c