Problem with GNU_PROPERTY_X86_ISA_1_NEEDED

H.J. Lu hjl.tools@gmail.com
Fri Jan 29 12:28:31 GMT 2021


On Fri, Jan 29, 2021 at 1:39 AM Manuel Lauss via Binutils
<binutils@sourceware.org> wrote:
>
> Hello,
>
> I've been building a userland for an AMD E-450 (gcc march=btver1) on
> a much more modern and faster x86 host (gcc-10.2.1, binutils-2.35.1, with
> ld, not gold)
>
> Now, the machine does not boot because up-to-date  glibc devel says this:
>
> /lib64/libc.so.6: CPU ISA level is lower than required
>
> readelf -n libc.so.6 says:
> Displaying notes found in: .note.gnu.property
>  Owner                Data size        Description
>  GNU                  0x00000010       NT_GNU_PROPERTY_TYPE_0
>      Properties: x86 ISA needed: x86-64-baseline, x86-64-v2, x86-64-v3

How did you build and configure glibc? Mine has

[hjl@gnu-skx-1 build-x86_64-linux]$ readelf -n libc.so

Displaying notes found in: .note.gnu.property
  Owner                Data size Description
  GNU                  0x00000030 NT_GNU_PROPERTY_TYPE_0
      Properties: x86 ISA needed: x86-64-baseline
x86 feature used: x86, x87, XMM, YMM, ZMM

Please use "readelf -n" on all .os files to find out which ones have
x86-64-v3 in

Properties: x86 ISA needed: XXX

> x86-64-v3 is supported by the build machine, but the btver1 is at most
> baseline.  GCC does not generate this property; is this caused by ld?
> If so, is there a commandline switch to force baseline?

Baseline is the default.

> I stripped the note from a few libs and applications, which got kernel
> to boot systemd, however it eventually causes a hard reboot.
>
>
> I also saw this on a kabylake core-i5 (gcc -march=skylake, same
> toolchain as above):
>
> $ readelf -n /lib64/libc.so.6
>
> Displaying notes found in: .note.gnu.property
>  Owner                Data size        Description
>  GNU                  0x00000030       NT_GNU_PROPERTY_TYPE_0
>      Properties: x86 ISA needed: x86-64-baseline, x86-64-v2, x86-64-v3
>        x86 feature used: x86, x87, XMM, YMM, ZMM
>        x86 ISA used: x86-64-baseline, x86-64-v2, x86-64-v3, x86-64-v4
>
> x86-64-v4  and ZMM can't be correct here?  At least this one boots and
> runs just fine.

The same libc.so binary supports ZMM.  Otherwise ZMM won't be usable
on ZMM machines with the same libc.so.

-- 
H.J.


More information about the Binutils mailing list