Bug 20140

Summary: CpuAVX512VL should be treated like Cpu64
Product: binutils Reporter: H.J. Lu <hjl.tools>
Component: gasAssignee: Not yet assigned to anyone <unassigned>
Status: RESOLVED FIXED    
Severity: normal CC: kirill.yukhin
Priority: P2    
Version: 2.27   
Target Milestone: 2.27   
Host: Target: x86
Build: Last reconfirmed:

Description H.J. Lu 2016-05-24 18:58:10 UTC
An 128-bit AVX512CD instruction

vpconflictd	%xmm0, %xmm15	

requires AVX512VL.  But I got

 [hjl@gnu-6 tmp]$ cat a.s
.arch corei7
.arch .avx512f
.arch .avx512cd
vpconflictd	%xmm0, %xmm15	
[hjl@gnu-6 tmp]$ gcc -c a.s               
[hjl@gnu-6 tmp]$

It should be an error.
Comment 1 Sourceware Commits 2016-05-25 22:06:59 UTC
The master branch has been updated by H.J. Lu <hjl@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=73b090a922a5f43931f0ec10b1b1b9507c819ebf

commit 73b090a922a5f43931f0ec10b1b1b9507c819ebf
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed May 25 14:59:05 2016 -0700

    Require another match for AVX512VL
    
    The AVX512VL bit alone isn't sufficient to select a 128-bit or 256-bit
    AVX512 instruction.  We must match another AVX512 bit.
    
    	PR gas/20140
    	* config/tc-i386.c (cpu_flags_match): Require another match
    	for AVX512VL.
    	* testsuite/gas/i386/i386.exp: Run avx512vl-1, avx512vl-2,
    	x86-64-avx512vl-1 and x86-64-avx512vl-2.
    	* testsuite/gas/i386/avx512vl-1.l: New file.
    	* testsuite/gas/i386/avx512vl-1.s: Likewise.
    	* testsuite/gas/i386/avx512vl-2.l: Likewise.
    	* testsuite/gas/i386/avx512vl-2.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl-1.l: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl-1.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl-2.l: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl-2.s: Likewise.
Comment 2 H.J. Lu 2016-05-25 22:36:49 UTC
Fixed for 2.27.