Re: [PATCH v2 2/4] perf record: implement -z=<level> and --mmap-flush=<thres> options

From: Alexey Budankov
Date: Wed Feb 20 2019 - 10:19:56 EST



On 12.02.2019 16:09, Jiri Olsa wrote:
> On Mon, Feb 11, 2019 at 11:22:38PM +0300, Alexey Budankov wrote:
>>
>> Implement -z,--compression_level=<n> and --mmap-flush=<dump_least_size>
>> options as well as a special PERF_RECORD_COMPRESSED record that contains
>> compressed parts of kernel data buffer.
>>
>> Because compression requires auxilary memory to implement encoding of
>> kernel data record->opts.nr_cblocks == -1 signifies to preallocate single
>> AIO data buffer aio.data[0] without accompnying AIO control blocks.
>>
>> Signed-off-by: Alexey Budankov <alexey.budankov@xxxxxxxxxxxxxxx>
>> ---
>> Changes in v2:
>> - enabled allocation aio data buffers for compression
>>
>> ---
>> tools/perf/Documentation/perf-record.txt | 9 ++
>> tools/perf/builtin-record.c | 110 +++++++++++++++++++----
>> tools/perf/perf.h | 2 +
>> tools/perf/util/env.h | 10 +++
>> tools/perf/util/event.c | 1 +
>> tools/perf/util/event.h | 7 ++
>> tools/perf/util/evlist.c | 6 +-
>> tools/perf/util/evlist.h | 3 +-
>> tools/perf/util/header.c | 45 +++++++++-
>> tools/perf/util/header.h | 1 +
>> tools/perf/util/mmap.c | 98 ++++++++++++--------
>> tools/perf/util/mmap.h | 7 +-
>> tools/perf/util/session.h | 2 +
>> 13 files changed, 240 insertions(+), 61 deletions(-)
>
> this patch is super complicated.. please think of reviewers
> when writing code ;-)
>
> it needs to be split to small logical patches,
> where each change is explained in changelog

Yes, Will do.

Thanks,
Alexey

>
> jirka
>