Re: [PATCH/RFC 12/16] perf tools: Reduce lock contention when processing events
From: Jiri Olsa
Date: Mon Dec 14 2015 - 03:43:20 EST
On Thu, Dec 10, 2015 at 04:53:31PM +0900, Namhyung Kim wrote:
> When multi-thread is enabled, the machine->threads_lock is contented
> as all worker threads try to grab the writer lock using the
> machine__findnew_thread(). Usually, the thread they're looking for is
> in the tree so they only need the reader lock though.
>
> Thus try machine__find_thread() first, and then fallback to the
> 'findnew' API. This will improve the performance.
found one other place, but I guess you chose those
based on profiling the contention?
parent lookup in machine__process_fork_event
jirka
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/