From: Ian Rogers <irogers@google.com>
To: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Namhyung Kim <namhyung@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Jiri Olsa <jolsa@kernel.org>, Ian Rogers <irogers@google.com>,
Adrian Hunter <adrian.hunter@intel.com>,
Kan Liang <kan.liang@linux.intel.com>,
Athira Rajeev <atrajeev@linux.vnet.ibm.com>,
linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org,
Steinar Gunderson <sesse@google.com>,
Matt Fleming <matt@readmodwrite.com>
Subject: [PATCH v1 0/2] Try to avoid some qsorts
Date: Wed, 3 Jul 2024 10:21:15 -0700 [thread overview]
Message-ID: <20240703172117.810918-1-irogers@google.com> (raw)
Reference count checking doesn't work well with rbtree due to the need
for counts on each child and parent edge. As such the reference count
checking changes removed rbtree and replaced them with sorted
arrays. There have been instances where sorting has been shown to be a
regression:
https://lore.kernel.org/lkml/20240521165109.708593-1-irogers@google.com/
These patches address a further 2 cases in comm and dsos, avoiding a
sort when the array is already sorted at the cost of an O(n) memmove.
Ian Rogers (2):
perf comm str: Avoid sort during insert
perf dsos: When adding a dso into sorted dsos maintain the sort order
tools/perf/util/comm.c | 29 ++++++++++++++++++-----------
tools/perf/util/dsos.c | 26 +++++++++++++++++++++-----
2 files changed, 39 insertions(+), 16 deletions(-)
--
2.45.2.803.g4e1b14247a-goog
next reply other threads:[~2024-07-03 17:21 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-03 17:21 Ian Rogers [this message]
2024-07-03 17:21 ` [PATCH v1 1/2] perf comm str: Avoid sort during insert Ian Rogers
2024-07-03 17:35 ` Matt Fleming
2024-07-03 17:21 ` [PATCH v1 2/2] perf dsos: When adding a dso into sorted dsos maintain the sort order Ian Rogers
2024-07-03 21:46 ` Namhyung Kim
2024-07-04 19:57 ` [PATCH v1 0/2] Try to avoid some qsorts Namhyung Kim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240703172117.810918-1-irogers@google.com \
--to=irogers@google.com \
--cc=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=atrajeev@linux.vnet.ibm.com \
--cc=jolsa@kernel.org \
--cc=kan.liang@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=matt@readmodwrite.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=sesse@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®