[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <157623141704.30329.9522840249744393883.tip-bot2@tip-bot2>
Date: Fri, 13 Dec 2019 10:03:37 -0000
From: "tip-bot2 for Shile Zhang" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Shile Zhang <shile.zhang@...ux.alibaba.com>,
"Peter Zijlstra (Intel)" <peterz@...radead.org>,
Josh Poimboeuf <jpoimboe@...hat.com>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
linux-kbuild@...r.kernel.org, Ingo Molnar <mingo@...nel.org>,
x86 <x86@...nel.org>, LKML <linux-kernel@...r.kernel.org>
Subject: [tip: core/objtool] x86/unwind/orc: Remove boot-time ORC unwind
tables sorting
The following commit has been merged into the core/objtool branch of tip:
Commit-ID: f14bf6a350dfd6613dbf91be5b423bc7eab690da
Gitweb: https://git.kernel.org/tip/f14bf6a350dfd6613dbf91be5b423bc7eab690da
Author: Shile Zhang <shile.zhang@...ux.alibaba.com>
AuthorDate: Wed, 04 Dec 2019 08:46:33 +08:00
Committer: Ingo Molnar <mingo@...nel.org>
CommitterDate: Fri, 13 Dec 2019 10:47:58 +01:00
x86/unwind/orc: Remove boot-time ORC unwind tables sorting
Now that the orc_unwind and orc_unwind_ip tables are sorted at build time,
remove the boot time sorting pass.
No change in functionality.
[ mingo: Rewrote the changelog and code comments. ]
Signed-off-by: Shile Zhang <shile.zhang@...ux.alibaba.com>
Acked-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Cc: Josh Poimboeuf <jpoimboe@...hat.com>
Cc: Masahiro Yamada <yamada.masahiro@...ionext.com>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: linux-kbuild@...r.kernel.org
Link: https://lkml.kernel.org/r/20191204004633.88660-8-shile.zhang@linux.alibaba.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
arch/x86/kernel/unwind_orc.c | 8 +++++---
scripts/link-vmlinux.sh | 5 ++++-
2 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/arch/x86/kernel/unwind_orc.c b/arch/x86/kernel/unwind_orc.c
index 332ae65..abdf891 100644
--- a/arch/x86/kernel/unwind_orc.c
+++ b/arch/x86/kernel/unwind_orc.c
@@ -273,9 +273,11 @@ void __init unwind_init(void)
return;
}
- /* Sort the .orc_unwind and .orc_unwind_ip tables: */
- sort(__start_orc_unwind_ip, num_entries, sizeof(int), orc_sort_cmp,
- orc_sort_swap);
+ /*
+ * Note, the orc_unwind and orc_unwind_ip tables were already
+ * sorted at build time via the 'sorttable' tool.
+ * It's ready for binary search straight away, no need to sort it.
+ */
/* Initialize the fast lookup table: */
lookup_num_blocks = orc_lookup_end - orc_lookup;
diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh
index a81aa76..c287ad9 100755
--- a/scripts/link-vmlinux.sh
+++ b/scripts/link-vmlinux.sh
@@ -306,7 +306,10 @@ vmlinux_link vmlinux "${kallsymso}" ${btf_vmlinux_bin_o}
if [ -n "${CONFIG_BUILDTIME_TABLE_SORT}" ]; then
info SORTTAB vmlinux
- sorttable vmlinux
+ if ! sorttable vmlinux; then
+ echo >&2 Failed to sort kernel tables
+ exit 1
+ fi
fi
info SYSMAP System.map
Powered by blists - more mailing lists