Re: [PATCH v3 14/26] objtool: Optimize read_sections()

From: Miroslav Benes
Date: Wed Mar 25 2020 - 08:10:36 EST


On Tue, 24 Mar 2020, Peter Zijlstra wrote:

> Perf showed that __hash_init() is a significant portion of
> read_sections(), so instead of doing a per section rela_hash, use an
> elf-wide rela_hash.
>
> Statistics show us there are about 1.1 million relas, so size it
> accordingly.
>
> This reduces the objtool on vmlinux.o runtime to a third, from 15 to 5
> seconds.
>
> Signed-off-by: Peter Zijlstra (Intel) <peterz@xxxxxxxxxxxxx>
> Acked-by: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>

Reviewed-by: Miroslav Benes <mbenes@xxxxxxx>

M