[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <BN8PR21MB136298F3A0852DAC38E05DB3F7600@BN8PR21MB1362.namprd21.prod.outlook.com>
Date: Wed, 30 Oct 2019 03:10:23 +0000
From: Steve MacLean <Steve.MacLean@...rosoft.com>
To: Jiri Olsa <jolsa@...hat.com>,
Steve MacLean <steve.maclean@...ux.microsoft.com>
CC: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Namhyung Kim <namhyung@...nel.org>,
Stephane Eranian <eranian@...gle.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH 3/4] perf inject --jit: Remove //anon mmap events
> anyway, I wonder if you could just use thread::priv flag for that, like:
>
> thread = machine__findnew_thread(machine, pid, pid);
> if (!thread)
> bad
>
> (int) thread->priv = 1;
>
> and check on thread->priv when ruling the pid out, should be faster then maintain rb tree
>
> thanks,
> jirka
I agree reusing the existing data structure is a better approach. I have drafted a change reusing the void* priv field. It seems looks like it is currently safe to use during perf inject.
I will test it tomorrow then send the new patch
Powered by blists - more mailing lists