kraj / glibc

Mirror of GNU C library
GNU General Public License v2.0
13 stars 7 forks source link

I can't build glibc on computer that does not support evex 512 instruction with default configuration #3

Open zcj5918 opened 1 year ago

zcj5918 commented 1 year ago

I just use configure and make -j, yet cannot build gblic 2.37, I think the reason is my E5-2678v3 CPU does not support avx512 instruction set. Can I disable avx512 instruction set before compiling?

When I use make, I received these:

../sysdeps/x86_64/multiarch/memcmpeq-evex.S: Assembler messages: ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:115: 错误: no such instruction: vpcmpneqb (%rdi),%zmm18,%k1{%k2}' ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:123: 错误: no such instruction:vpcmpneqb -(64 1)(%rdi,%rdx),%zmm17,%k1' ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:136: 错误: no such instruction: vpcmpneqb (%rdi),%zmm17,%k1' ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:146: 错误: no such instruction:vpcmpneqb 64(%rdi),%zmm18,%k1' ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:157: 错误: no such instruction: `vpcmpneqb (64 2)(%rdi),%zmm19,%k1' ../sysdeps/x86_64/multiarch/memcmpeq-evex.S:163: 错误: no such instruction: vpcmpneqb (64 * 3)(%rdi),%zmm20,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S: Assembler messages: ../sysdeps/x86_64/multiarch/strchr-evex-base.S:64: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:124: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:155: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:171: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:182: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:193: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:214: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:215: 错误: no such instruction: vpcmpneqb %zmm18,%zmm16,%k2' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:219: 错误: no such instruction:vpcmpneqb %zmm19,%zmm16,%k3{%k1}' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:220: 错误: no such instruction: vpcmpneqb %zmm20,%zmm16,%k4{%k2}' ../sysdeps/x86_64/multiarch/memchr-evex-base.S: Assembler messages: ../sysdeps/x86_64/multiarch/memchr-evex-base.S:229: 错误: no such instruction:vpcmpneqb (64 4)(%rdi),%zmm17,%k1' ../sysdeps/x86_64/multiarch/memchr-evex-base.S: Assembler messages: ../sysdeps/x86_64/multiarch/memchr-evex-base.S:229: 错误: no such instruction: `vpcmpneqb (64 4)(%rdi),%zmm17,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S: Assembler messages: ../sysdeps/x86_64/multiarch/strchr-evex-base.S:64: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:124: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:155: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:171: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:182: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:193: 错误: no such instruction:vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:214: 错误: no such instruction: vpcmpneqb %zmm17,%zmm16,%k1' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:215: 错误: no such instruction:vpcmpneqb %zmm18,%zmm16,%k2' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:219: 错误: no such instruction: vpcmpneqb %zmm19,%zmm16,%k3{%k1}' ../sysdeps/x86_64/multiarch/strchr-evex-base.S:220: 错误: no such instruction:vpcmpneqb %zmm20,%zmm16,%k4{%k2}'

My Environment: g++ 7+ Ubuntu 16.04.7 LTS E5-2678V3 X 2 nvidia 2080Ti x2

From what I know vpcmpneqb is based on avx512 set, can anyone else kindly tell me how to disable avx512 before compiling?

baneta commented 7 months ago

Hello. I know your comment too old, but I had same issue when working on old CentOS 7. I've upgraded GNU binutils (This contains new version of GNU Assembler) by compiling from it's source and it worked.

kraj commented 7 months ago

try to run configure with --disable-avx512