History

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. ]

Shile Zhang committed 6 years ago

Commit f14bf6a1 parent 57fa1892 files · +9 −4Browse files

Unified · Split

2 files
  1. arch/x86/kernel/unwind_orc.c +5 −3
  2. scripts/link-vmlinux.sh +4 −1
arch/x86/kernel/unwind_orc.c+5−3
@@ -273,9 +273,11 @@ void __init unwind_init(void) · 272 unmodified lines
273 return;273 return;
274 }274 }
275 275
276 /* Sort the .orc_unwind and .orc_unwind_ip tables: */276 /*
277 sort(__start_orc_unwind_ip, num_entries, sizeof(int), orc_sort_cmp,277 * Note, the orc_unwind and orc_unwind_ip tables were already
278 orc_sort_swap);278 * sorted at build time via the 'sorttable' tool.
279 * It's ready for binary search straight away, no need to sort it.
280 */
279 281
280 /* Initialize the fast lookup table: */282 /* Initialize the fast lookup table: */
281 lookup_num_blocks = orc_lookup_end - orc_lookup;283 lookup_num_blocks = orc_lookup_end - orc_lookup;
scripts/link-vmlinux.sh+4−1
@@ -306,7 +306,10 @@ vmlinux_link vmlinux "${kallsymso}" ${btf_vmlinux_bin_o} · 305 unmodified lines
306 306
307if [ -n "${CONFIG_BUILDTIME_TABLE_SORT}" ]; then307if [ -n "${CONFIG_BUILDTIME_TABLE_SORT}" ]; then
308 info SORTTAB vmlinux308 info SORTTAB vmlinux
309 sorttable vmlinux309 if ! sorttable vmlinux; then
310 echo >&2 Failed to sort kernel tables
311 exit 1
312 fi
310fi313fi
311 314
312info SYSMAP System.map315info SYSMAP System.map