buildroot/package/binutils
Thomas Petazzoni a904fb2ac4 package/binutils: prevent selecting 2.37 for AVX512 systems
Support for the AVX512FP16 instructions was added in binutils
2.38. See the binutils 2.38 releases notes [0] that state:

    X86:
    [...]
      * Add support for Intel AVX512_FP16 instructions.

[0] https://sourceware.org/pipermail/binutils/2022-February/119721.html

It turns out that when building GCC 12.x, some of these AVX512FP16
instructions are now used, and therefore when binutils < 2.38 is used,
the build fails as the assembler does not recognize those
instructions:

/tmp/ccChzL2g.s: Assembler messages:
/tmp/ccChzL2g.s:20: Error: no such instruction: `vmovw 24(%esp),%xmm2'
/tmp/ccChzL2g.s:21: Error: no such instruction: `vmovw 28(%esp),%xmm3'
/tmp/ccChzL2g.s:22: Error: no such instruction: `vmovw 32(%esp),%xmm4'
/tmp/ccChzL2g.s:23: Error: no such instruction: `vmovw 36(%esp),%xmm5'
/tmp/ccChzL2g.s:30: Error: no such instruction: `vcvtsh2ss %xmm2,%xmm6,%xmm6'
/tmp/ccChzL2g.s:36: Error: no such instruction: `vcvtsh2ss %xmm3,%xmm6,%xmm6'
/tmp/ccChzL2g.s:42: Error: no such instruction: `vcvtsh2ss %xmm4,%xmm7,%xmm7'
/tmp/ccChzL2g.s:48: Error: no such instruction: `vcvtsh2ss %xmm5,%xmm1,%xmm1'
/tmp/ccChzL2g.s:80: Error: no such instruction: `vcvtss2sh (%esp),%xmm1,%xmm1'
/tmp/ccChzL2g.s:96: Error: no such instruction: `vcvtss2sh (%esp),%xmm0,%xmm0'
/tmp/ccChzL2g.s💯 Error: no such instruction: `vucomish %xmm1,%xmm1'
/tmp/ccChzL2g.s:103: Error: no such instruction: `vucomish %xmm0,%xmm0'
/tmp/ccChzL2g.s:122: Error: no such instruction: `vucomish %xmm2,%xmm2'

The same issue does not occur with GCC 11.x, but nothing prevents
other packages than GCC to use those instructions, so the problem
really lies on the binutils side missing the support for those
instructions.

Also, in Buildroot, we do not distinguish AVX512 in general from
AVX512FP16 specifically, so our only option is to make binutils 2.37
unavailable for AVX512 systems even if some of them perhaps don't
support AVX512FP16 anyway. This seems like a reasonable trade-off, as
binutils 2.38 is anyway already the default in Buildroot, and
AVX512-capable systems are fairly recent, and therefore using a recent
binutils version should not be a problem on these platforms.

Fixes:

  http://autobuild.buildroot.net/results/eb6e28c934654e6d714973415a2fb452f9580279/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2022-10-30 20:31:41 +01:00
..
2.37 package/binutils: fixes glibc build compiled with -Os on x86 2022-02-14 22:01:36 +01:00
2.38 package/binutils: add version 2.38 2022-04-23 16:05:39 +02:00
2.39 package/binutils: add version 2.39 2022-08-13 00:03:44 +02:00
arc-2020.09-release
…
Config.in package/binutils: zlib is mandatory 2021-11-10 21:40:39 +01:00
Config.in.host package/binutils: prevent selecting 2.37 for AVX512 systems 2022-10-30 20:31:41 +01:00
binutils.hash package/binutils: remove 2.36.1 and make 2.38 default 2022-08-13 00:07:55 +02:00
binutils.mk package/binutils: fix typo in variable name 2022-08-14 17:13:57 +02:00