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]
Date:   Thu, 11 Oct 2018 19:15:50 +0300
From:   Alexey Budankov <alexey.budankov@...ux.intel.com>
To:     Jiri Olsa <jolsa@...hat.com>
Cc:     Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Arnaldo Carvalho de Melo <acme@...nel.org>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Namhyung Kim <namhyung@...nel.org>,
        Andi Kleen <ak@...ux.intel.com>,
        linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v12 2/3]: perf record: enable asynchronous trace writing

On 11.10.2018 16:45, Jiri Olsa wrote:
> On Tue, Oct 09, 2018 at 11:58:53AM +0300, Alexey Budankov wrote:
> 
> SNIP
> 
>> @@ -329,7 +469,7 @@ static int record__mmap_evlist(struct record *rec,
>>  
>>  	if (perf_evlist__mmap_ex(evlist, opts->mmap_pages,
>>  				 opts->auxtrace_mmap_pages,
>> -				 opts->auxtrace_snapshot_mode) < 0) {
>> +				 opts->auxtrace_snapshot_mode, opts->nr_cblocks) < 0) {
>>  		if (errno == EPERM) {
>>  			pr_err("Permission error mapping pages.\n"
>>  			       "Consider increasing "
>> @@ -513,6 +653,29 @@ static struct perf_event_header finished_round_event = {
>>  	.type = PERF_RECORD_FINISHED_ROUND,
>>  };
>>  
>> +#ifdef HAVE_AIO_SUPPORT
>> +static void record__mmap_read_sync(struct record *rec)
>> +{
>> +	int i;
>> +	struct perf_evlist *evlist = rec->evlist;
>> +	struct perf_mmap *maps = evlist->mmap;
>> +
>> +	if (!rec->opts.nr_cblocks)
>> +		return;
>> +
>> +	for (i = 0; i < evlist->nr_mmaps; i++) {
>> +		struct perf_mmap *map = &maps[i];
>> +
>> +		if (map->base)
>> +			record__aio_sync(map);
>> +	}
>> +}
>> +#else
>> +static void record__mmap_read_sync(struct record *rec __maybe_unused)
>> +{
>> +}
>> +#endif
> 
> please move this up so we have just one  'ifdef HAVE_AIO_SUPPORT' block
> 
> and change the name to record__aio_mmap_read_sync, so it's obvious it's
> aio related, like the rest of the functions you added

Accepted.

> 
> thanks,
> jirka
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ