[Buildroot] [PATCH v2] toolchain: update gcc bug 99140
Arnout Vandecappelle
arnout at mind.be
Mon Aug 23 20:01:19 UTC 2021
On 21/08/2021 23:33, Giulio Benetti wrote:
> Gcc bug 99140 has been fixed on gcc 8.x but reappeared on gcc 9.x while
> it's been fixed on gcc 10.x+. So let's update
> BR2_TOOLCHAIN_HAS_GCC_BUG_99140 accordingly.
>
> Fixes:
> http://autobuild.buildroot.net/results/c55/c55f50a8d657695f0d5492c32efa666254cd7f99/
>
> Signed-off-by: Giulio Benetti <giulio.benetti at benettiengineering.com>
> ---
> V1->V2:
> * gcc 8.x works, gcc 9.x doesn't, gcc 10.x+ work
> ---
> toolchain/Config.in | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/toolchain/Config.in b/toolchain/Config.in
> index c35c52d142..d033ce3962 100644
> --- a/toolchain/Config.in
> +++ b/toolchain/Config.in
> @@ -165,10 +165,12 @@ config BR2_TOOLCHAIN_HAS_GCC_BUG_93847
>
> # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99410
> # Error: branch offset out of range on Nios II. This bug
> -# no longer exists in gcc >= 8.x.
> +# no longer exists in gcc 8.x but reappeared on gcc 9.x and has been
> +# fixed on gcc 10.x.
> config BR2_TOOLCHAIN_HAS_GCC_BUG_99140
> bool
> - default y if BR2_nios2 && !BR2_TOOLCHAIN_GCC_AT_LEAST_8
> + default y if BR2_nios2
> + depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_8 || BR2_TOOLCHAIN_GCC_AT_LEAST_9
Unless I'm very mistaken, this is basically saying "depends on any GCC version
except GCC 8". However, from your commit message, it seems it should be "depends
on GCC < 8 or GCC 9". To simplify the logic, I would say:
default y if !BR2_TOOLCHAIN_GCC_AT_LEAST_8
default y if BR2_TOOLCHAIN_GCC_AT_LEAST_9 && !BR2_TOOLCHAIN_GCC_AT_LEAST_10
depends on BR2_nios2
Regards,
Arnout
>
> # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101737
> # ICE: SH4 -Os causes internal compiler error. This bug
>
More information about the buildroot
mailing list