Force _start to be the top frame for the linker.
I noticed that sometimes the old unwinder will add an extra PC 0 frame
after this change, but the new unwinder works in all cases. I'm not going
to fix the old unwinder since I plan to remove it very soon.
Bug: 67784501
Test: Forced a crash in the linker and verified that the unwind
Test: stops in __dl_start. Tested on arm/aarch64/x86/x86_64.
Change-Id: Id6585768023256be5c1d341df7b06b786a220b40
diff --git a/linker/arch/arm/begin.S b/linker/arch/arm/begin.S
index 480047a..80d9fe1 100644
--- a/linker/arch/arm/begin.S
+++ b/linker/arch/arm/begin.S
@@ -29,6 +29,9 @@
#include <private/bionic_asm.h>
ENTRY(_start)
+ // Force unwinds to end in this function.
+ .cfi_undefined r14
+
mov r0, sp
bl __linker_init