lkml.org 
[lkml]   [2021]   [Jul]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v8 20/22] perf session: Load data directory files for analysis
On Wed, Jun 30, 2021 at 06:54:59PM +0300, Alexey Bayduraev wrote:

SNIP

> + while ((ret >= 0) && readers) {
> + if (session_done())
> + return 0;
> +
> + if (rd[i].state.eof) {
> + i = (i + 1) % session->nr_readers;
> + continue;
> + }
> +
> + ret = reader__read_event(&rd[i], session, &prog);
> + if (ret < 0)
> + break;
> + if (ret == READER_EOF) {
> + ret = reader__mmap(&rd[i], session);
> + if (ret < 0)
> + goto out_err;
> + if (ret == READER_EOF)
> + readers--;
> + }
> +
> + /*
> + * Processing 10MBs of data from each reader in sequence,
> + * because that's the way the ordered events sorting works
> + * most efficiently.
> + */
> + if (rd[i].state.size >= 10*1024*1024) {
> + rd[i].state.size = 0;
> + i = (i + 1) % session->nr_readers;
> + }

hi,
so this was sort of hack to make this faster.. we need some
justification for this and make that configurable as well,
if we keep it

jirka

\
 
 \ /
  Last update: 2021-07-02 12:33    [W:0.261 / U:0.612 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site