public inbox for libc-help@sourceware.org
 help / color / mirror / Atom feed
From: Manuel Lauss <manuel.lauss@gmail.com>
To: Florian Weimer <fweimer@redhat.com>
Cc: Manuel Lauss via Libc-help <libc-help@sourceware.org>
Subject: Re: How to set x86 ISA needed property?
Date: Wed, 27 Jan 2021 17:06:50 +0100	[thread overview]
Message-ID: <CAOLZvyEciQJJjdP-oS2sWu97Emmi+--+E7u+uJuFCOxO76L_xw@mail.gmail.com> (raw)
In-Reply-To: <87im7i4d08.fsf@oldenburg.str.redhat.com>

Servus Florian,


On Wed, Jan 27, 2021 at 4:26 PM Florian Weimer <fweimer@redhat.com> wrote:
>
> * Manuel Lauss via Libc-help:
>
> > I've been building a userland for an AMD E-450 (gcc march=btver1) on
> > a much more modern and faster x86 host.
> > Now, the machione does not boot because up-to-date  glibc devel says this:
> >
> > /lib64/libc.so.6: CPU ISA level is lower than required
> >
> > readelf 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
> >
> > x86-64-v3 is supported by the build machine, but the btver1 is at most -v2.
> > This used to work in the past; is there a way to force glibc to a certain level?
> > (binutils-2.35.1, gcc-10.2.1, glibc master as of 27.01.2021).
>
> What does “gcc -v”?  What are you glibc configure/build flags?

# gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/10.2.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with:
/tmp-ram/portage/sys-devel/gcc-10.2.0-r5/work/gcc-10.2.0/configure
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/10.2.0
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.2.0
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.2.0/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.2.0/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/include/g++-v10
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/10.2.0/python
--enable-languages=c,c++ --enable-obsolete --enable-secureplt
--disable-werror --with-system-zlib --disable-nls
--enable-checking=release --with-bugurl=https://bugs.gentoo.org/
--with-pkgversion='Gentoo 10.2.0-r5 p6' --disable-esp
--enable-libstdcxx-time --enable-shared --enable-threads=posix
--enable-__cxa_atexit --enable-clocale=gnu --enable-multilib
--with-multilib-list=m32,m64 --disable-fixed-point
--enable-targets=all --enable-libgomp --disable-libssp
--disable-libada --disable-systemtap --disable-vtable-verify
--disable-libvtv --with-zstd --enable-lto --with-isl
--disable-isl-version-check --disable-libsanitizer
--disable-default-pie --disable-default-ssp --with-arch=btver1
--with-tune=btver1
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 10.2.0 (Gentoo 10.2.0-r5 p6)



This is the gentoo ebuild's configure invocation:

configure --enable-stack-protector=no
--enable-stackguard-randomization --disable-cet --enable-kernel=3.2.0
--without-selinux --without-cvs --disable-werror --enable-bind-now
--build=x8
6_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --disable-profile
--without-gd --with-headers=/usr/include --prefix=/usr
--sysconfdir=/etc --localstatedir=/var --libdir=$(prefix)/lib64
--mandir=$(prefix)/share/man --infodir=$(prefix)/share/info
--libexecdir=$(libdir)/misc/glibc
--with-bugurl=https://bugs.gentoo.org/ --with-pkgversion=Gentoo
2.32-r7 p6 --enable-crypt --disable-static-pie --disable-systemtap
--disable-nscd libc_cv_complocaledir=${exec_prefix}/lib/locale
--disable-ti
mezone-tools

> This is expected to happen only if you use something like
> -march=x86-64-v3 to build glibc, and only with recent toolchain
> version.  I'm surprised you are hitting this with GCC 10, which does not
> implement -march=x86-64-v3.

I'm surprised as well, though not all libs/executables have the property set,
most are missing it.  Gentoo's patches to gcc don't add the property code
either, i'll check binutils next.

I removed the note, and this allowed systemd to start.

Danke!
     Manuel

  reply	other threads:[~2021-01-27 16:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-27 15:04 Manuel Lauss
2021-01-27 15:26 ` Florian Weimer
2021-01-27 16:06   ` Manuel Lauss [this message]
2021-01-27 16:14     ` Florian Weimer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOLZvyEciQJJjdP-oS2sWu97Emmi+--+E7u+uJuFCOxO76L_xw@mail.gmail.com \
    --to=manuel.lauss@gmail.com \
    --cc=fweimer@redhat.com \
    --cc=libc-help@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).