This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 1/2] Add _arch_/_cpu_ to index_*/bit_* in x86 cpu-features.h


On Fri, Mar 11, 2016 at 2:29 PM, Roland McGrath <roland@hack.frob.com> wrote:
>> On Fri, Mar 11, 2016 at 2:00 PM, Roland McGrath <roland@hack.frob.com> wrote:
>> >> Sorry I didn't mention that I tested it on both x86-64 and i686 before
>> >> commit.
>> >
>> > But clearly you didn't!  The tree right now is broken, as I said.
>>
>> I double checked again with
>>
>> commit 6aa3e97e2530f9917f504eb4146af119a3f27229
>> Author: H.J. Lu <hjl.tools@gmail.com>
>> Date:   Thu Mar 10 05:26:46 2016 -0800
>>
>>     Add _arch_/_cpu_ to index_*/bit_* in x86 cpu-features.h
>>
>> on x86-64 and i686.  I only see:
>>
>> [hjl@gnu-6 build-i686-linux]$ ./nptl/tst-cleanupx4
>> test 0
>> clh (1)
>> clh (2)
>> clh (3)
>> test 1
>> clh (1)
>> clh (4)
>> clh (5)
>> clh (6)
>> test 2
>> clh (7)
>> clh (8)
>> global = 64, expected 120
>> test 3
>> clh (1)
>> clh (2)
>> clh (9)
>> clh (10)
>> [hjl@gnu-6 build-i686-linux]$
>>
>> Did you remove the old build directory?
>
> http://130.211.48.148:8080/builders/glibc-x86_64-linux/builds/1125/steps/check%20%28clobber%29/logs/stdio

The error is

../sysdeps/x86_64/tst-audit10.c: In function âavx512_enabledâ:
../sysdeps/x86_64/tst-audit10.c:34:15: error: âbit_AVX512Fâ undeclared
(first use in this function)
   if (!(ebx & bit_AVX512F))

which is changed by

ommit 3c0f7407eedb524c9114bb675cd55b903c71daaa
Author: Florian Weimer <fweimer@redhat.com>
Date:   Mon Mar 7 16:00:25 2016 +0100

    tst-audit4, tst-audit10: Compile AVX/AVX-512 code separately [BZ #19269]

    This ensures that GCC will not use unsupported instructions before
    the run-time check to ensure support.

bit_AVX512F is defined in <cpuid.h>  from GCC.  Apparently, your GCC
doesn't have it.  You can try this patch.


-- 
H.J.
---
diff --git a/sysdeps/x86_64/Makefile b/sysdeps/x86_64/Makefile
index aa4a754..2525cc1 100644
--- a/sysdeps/x86_64/Makefile
+++ b/sysdeps/x86_64/Makefile
@@ -47,7 +47,11 @@ tests-pie += $(quad-pie-test)
 $(objpfx)tst-quad1pie: $(objpfx)tst-quadmod1pie.o
 $(objpfx)tst-quad2pie: $(objpfx)tst-quadmod2pie.o

-tests += tst-audit3 tst-audit4 tst-audit5 tst-audit6 tst-audit7 tst-audit10
+tests += tst-audit3 tst-audit4 tst-audit5 tst-audit6 tst-audit7
+
+ifeq (yes,$(config-cflags-avx512))
+tests += tst-audit10
+endif

 tests += tst-split-dynreloc
 LDFLAGS-tst-split-dynreloc = -Wl,-T,$(..)sysdeps/x86_64/tst-split-dynreloc.lds


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]