qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: roms/seabios-hppa can't be built with gcc-10: -fno-ipa-sra


From: Helge Deller
Subject: Re: roms/seabios-hppa can't be built with gcc-10: -fno-ipa-sra
Date: Fri, 24 Jul 2020 19:34:14 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0

On 22.07.20 21:11, Michael Tokarev wrote:
> Switching to gcc-10 makes seabios-hppa unbuildable.
> It fails at the final linking step with a lot of
> missing references to memcpy & memcmp all over the
> places.
>
> The notable difference between gcc-10 and previous
> gcc is that ccode32flat.o does _not_ have the text
> for these two functions but have two .isra.0:
>
> $ hppa-linux-gnu-nm ccode32flat.o | grep mem[sc]
> 000003e0 t memcmp
>          U memcpy
> 00002f38 t memcpy.isra.0
>          U memset
> 00003a84 t memset.isra.0
>
>
> while previous version of the compiler did have them:
>
> $ hppa-linux-gnu-nm ccode32flat.o | grep mem[sc]
> 000002fc t memcmp
> 0000370c t memcpy
> 0000036c t memset

I believe this is a compiler bug in gcc-10.
Adding other flags like -fno-builtin or similiar doesn't fix the issue.

> After adding -fno-ipa-sra to the gcc flags, the firmware
> is built successfully.
>
> I don't know what to make out of this. Previous versions
> of gcc apparently accepts -fno-ipa-sra too, for quite some
> time.  So maybe add this to the flags unconditionally?

I think this is currently the best way forward.
Do you want to send a patch, or should I just add this upstream
to seabios-hppa?

Helge



reply via email to

[Prev in Thread] Current Thread [Next in Thread]