public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Noah Goldstein <goldstein.w.n@gmail.com>
To: DJ Delorie <dj@redhat.com>
Cc: libc-alpha@sourceware.org, hjl.tools@gmail.com
Subject: Re: x86: Don't check PREFETCHWT1 in tst-cpu-features-cpuinfo.c
Date: Tue, 21 Mar 2023 13:01:09 -0500	[thread overview]
Message-ID: <CAFUsyfJPgnSQw=3==0UVBV5at4cnA-xRjJSEGFZOeCs3kR5vrA@mail.gmail.com> (raw)
In-Reply-To: <CAFUsyfJLh0yCr9DiJ6qHh3-zuneRFDyr8KA_y0cv5mn1A=nV-Q@mail.gmail.com>

On Fri, Mar 10, 2023 at 1:04 AM Noah Goldstein <goldstein.w.n@gmail.com> wrote:
>
> On Thu, Mar 9, 2023 at 9:43 PM DJ Delorie via Libc-alpha
> <libc-alpha@sourceware.org> wrote:
> >
> >
> > As not noted in the kernel sources:
> >
> > > /* Intel-defined CPU features, CPUID level 0x00000007:0 (ECX), word 16 */
> > > #define X86_FEATURE_AVX512VBMI          (16*32+ 1) /* AVX512 Vector Bit Manipulation instructions*/
> > > #define X86_FEATURE_UMIP                (16*32+ 2) /* User Mode Instruction Protection */
> >
> > vs glibc:
> >
> > > /* ECX.  */
> > > #define bit_cpu_PREFETCHWT1   (1u << 0)
> > > #define bit_cpu_AVX512_VBMI   (1u << 1)
> > > #define bit_cpu_UMIP          (1u << 2)
> >
> > Tested on the one machine I could find in our inventory that set that flag:
> >
> > - FAIL: elf/tst-cpu-features-cpuinfo
> > - FAIL: elf/tst-cpu-features-cpuinfo-static
> > -     27 FAIL
> > +     23 FAIL
> >
> > (there were two unrelated timeouts in the "before" results)
> >
> > From c4a62abbeac4ced531ced3999a2cd2d4fab6bdc6 Mon Sep 17 00:00:00 2001
> > From: DJ Delorie <dj@redhat.com>
> > Date: Thu, 9 Mar 2023 22:32:54 -0500
> > Subject: x86: Don't check PREFETCHWT1 in tst-cpu-features-cpuinfo.c
> >
> > Don't check PREFETCHWT1 against /proc/cpuinfo since kernel doesn't report
> > PREFETCHWT1 in /proc/cpuinfo.
> >
> > diff --git a/sysdeps/x86/tst-cpu-features-cpuinfo.c b/sysdeps/x86/tst-cpu-features-cpuinfo.c
> > index c25240774e..e963592c4b 100644
> > --- a/sysdeps/x86/tst-cpu-features-cpuinfo.c
> > +++ b/sysdeps/x86/tst-cpu-features-cpuinfo.c
> > @@ -217,7 +217,10 @@ do_test (int argc, char **argv)
> >    fails += CHECK_PROC (pku, PKU);
> >    fails += CHECK_PROC (popcnt, POPCNT);
> >    fails += CHECK_PROC (3dnowprefetch, PREFETCHW);
> > +#if 0
> > +  /* NB: /proc/cpuinfo doesn't report this feature.  */
> >    fails += CHECK_PROC (prefetchwt1, PREFETCHWT1);
> > +#endif
> >  #if 0
> >    /* NB: /proc/cpuinfo doesn't report this feature.  */
> >    fails += CHECK_PROC (ptwrite, PTWRITE);
> >
>
> LGTM.
Reviewed-by: Noah Goldstein <goldstein.w.n@gmail.com>

  parent reply	other threads:[~2023-03-21 18:01 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-10  3:43 DJ Delorie
2023-03-10  5:01 ` Noah Goldstein
2023-03-10  5:10   ` DJ Delorie
2023-03-10  7:04     ` Noah Goldstein
2023-03-10  7:04 ` Noah Goldstein
2023-03-20 19:01   ` DJ Delorie
2023-03-21 18:01   ` Noah Goldstein [this message]
2023-03-22  0:08     ` DJ Delorie

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='CAFUsyfJPgnSQw=3==0UVBV5at4cnA-xRjJSEGFZOeCs3kR5vrA@mail.gmail.com' \
    --to=goldstein.w.n@gmail.com \
    --cc=dj@redhat.com \
    --cc=hjl.tools@gmail.com \
    --cc=libc-alpha@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).