lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <9a6e9cd6-1ba2-3519-563f-c1eb45329539@linux.intel.com>
Date:   Thu, 9 Jul 2020 11:30:34 +0300
From:   Alexey Budankov <alexey.budankov@...ux.intel.com>
To:     Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Peter Zijlstra <a.p.zijlstra@...llo.nl>,
        Arnaldo Carvalho de Melo <acme@...hat.com>
Cc:     Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
        Jiri Olsa <jolsa@...nel.org>, adrian.hunter@...el.com
Subject: Re: [PATCH 0/2] perf: Allow closing siblings' file descriptors

Hi Alex,

On 08.07.2020 18:16, Alexander Shishkin wrote:
> Hi guys,
> 
> I've been looking at reducing the number of open file descriptors per perf
> session. If we retain one descriptor per event, in a large group they add
> up. At the same time, we're not actually using them for anything after the
> SET_OUTPUT and maybe SET_FILTER ioctls. So, this series is a stab at that.

PERF_EVENT_IOC_ENABLE, PERF_EVENT_IOC_DISABLE ioctls are still assumed to
work, right?

Asking w.r.t. functionality on --control fd:ctl_fd[,ack_fd] option for stat
and record modes [1].

Thanks,
Alexey

[1] https://lore.kernel.org/lkml/4af50c95-36f6-7a61-5a22-2949970fe7a5@linux.intel.com/

> 
> So, I added a new flag to the perf_event_open() that tells perf to keep
> the event around after its file descriptor gets closed, for as long as its
> group leader is alive. Since this is a new behavior, the flag is an opt-in.
> 
> I also hacked this into the perf tool (mostly perf record, but I'll hack
> stat as well if this general approach is agreeable).
> 
> Alexander Shishkin (2):
>   perf: Add closing sibling events' file descriptors
>   perf record: Support closing siblings' file descriptors
> 
>  include/linux/perf_event.h              |   7 ++
>  include/uapi/linux/perf_event.h         |   1 +
>  kernel/events/core.c                    | 149 +++++++++++++++++-------
>  tools/include/uapi/linux/perf_event.h   |   1 +
>  tools/lib/perf/evlist.c                 |  30 ++++-
>  tools/lib/perf/evsel.c                  |  21 ++++
>  tools/lib/perf/include/internal/evsel.h |   4 +
>  tools/perf/builtin-record.c             |  48 ++++++--
>  tools/perf/util/cpumap.c                |   4 +
>  tools/perf/util/evlist.c                |   4 +-
>  tools/perf/util/evsel.c                 |  17 ++-
>  tools/perf/util/evsel.h                 |   3 +
>  12 files changed, 234 insertions(+), 55 deletions(-)
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ