Re: [PATCH 19/24] alpha: discard .eh_frame and the relocation sections
From: Magnus Lindholm
Date: Thu Sep 03 2026 - 01:23:45 EST
Hi Matt,
On Tue, Sep 1, 2026 at 5:51 PM Matt Turner <mattst88@xxxxxxxxx> wrote:
>
> gcc emits .eh_frame for Alpha even though the kernel builds with
> -fno-asynchronous-unwind-tables, and nothing in the kernel consumes it:
> the stack trace code scans the stack for text addresses rather than
> unwinding DWARF. It was allocated in the loaded image, so dropping it
> shrinks vmlinux by about 1.1MB for a Marvel SMP configuration.
>
> The .rela* sections are equally useless, as the kernel image is not
> relocatable. The linker was already dropping their contents.
>
> Both were being placed as orphan sections, which is what drew attention
> to them.
>
> Assisted-by: Claude:claude-opus-5
> Signed-off-by: Matt Turner <mattst88@xxxxxxxxx>
> ---
I verified that .eh_frame and .rela* sections were present in the
linker input objects but absent from the final vmlinux. The resulting
compressed kernel image also booted successfully on an Alpha UP2000.
Tested-by: Magnus Lindholm <linmag7@xxxxxxxxx>
Reviewed-by: Magnus Lindholm <linmag7@xxxxxxxxx>