Re: [RFCv2 00/48] perf tools: Add threads to record command

From: Jiri Olsa
Date: Fri Sep 14 2018 - 04:23:15 EST


On Fri, Sep 14, 2018 at 11:29:10AM +0900, Namhyung Kim wrote:
> On Thu, Sep 13, 2018 at 07:10:35PM +0300, Alexey Budankov wrote:
> > Hi,
>
> Hello,
>
> >
> > On 13.09.2018 15:54, Jiri Olsa wrote:
> > > hi,
> > > sending *RFC* for threads support in perf record command.
> > >
> > > In big picture this patchset adds perf record --threads
> > > option that allows to create threads in following modes:
> > >
> > > 1) single thread mode (current)
> > >
> > > $ perf record ...
> > > $ perf record --threads=1 ...
> > >
> > > - all maps are read/stored under process thread
> > >
> > > 2) mode with specific (X) number of threads
> > >
> > > $ perf record --threads=X ...
> > >
> > > - maps are spread equaly among threads
> > >
> > > 3) mode that creates thread for every monitored memory map
> > >
> > > $ perf record --threads ...
> > >
> > > - which in perf record is equal to number of CPUs, and
> > > it pins each thread to its map's cpu:
> > >
> > > 4) TODO - NUMA aware threads/maps separation
> > > ...
> > >
> > > The perf.data stays as a single file.
>
> I'm not sure we really need to keep it as a single file. As it's a
> kind of big changes, we might consider breaking compatibility and use
> a directory structure.

moving the files into the perf.data at the end is actualy
not a lot code.. and I think it's one of the 'small' things
that make this feature more user friendly

jirka