Skip to content
  • H.J. Lu's avatar
    x86: Optimize with EVEX128 encoding for AVX512VL · 0089dace
    H.J. Lu authored
    We can optimize AVX512 instructions with EVEX128 only if AVX512VL is
    enabled:
    
    1. Instruction is an AVX512VL instruction. Or
    2. AVX512VL is enabled explicitly by -march=+avx512vl/".arch .avx512vl".
    
    We should optimize EVEX instructions with EVEX128 encoding when pseudo
    {evex} prefix is used.
    
    	* config/tc-i386.c (set_cpu_arch): Set cpu_arch_isa_flags.
    	(md_parse_option): Likewise.
    	(optimize_encoding): Check i.tm.cpu_flags and cpu_arch_isa_flags
    	for cpuavx512vl instead of cpu_arch_flags.  Optimize EVEX with
    	EVEX128 when EVEX encoding is required.
    	* testsuite/gas/i386/i386.exp: Run optimize-4, optimize-5,
    	x86-64-optimize-5 and x86-64-optimize-6.
    	* testsuite/gas/i386/optimize-1.d: Updated.
    	* testsuite/gas/i386/x86-64-optimize-2.d: Likewise.
    	* testsuite/gas/i386/optimize-4.d: New file.
    	* testsuite/gas/i386/optimize-4.s: Likewise.
    	* testsuite/gas/i386/optimize-5.d: Likewise.
    	* testsuite/gas/i386/optimize-5.s: Likewise.
    	* testsuite/gas/i386/x86-64-optimize-5.d: Likewise.
    	* testsuite/gas/i386/x86-64-optimize-5.s: Likewise.
    	* testsuite/gas/i386/x86-64-optimize-6.d: Likewise.
    	* testsuite/gas/i386/x86-64-optimize-6.s: Likewise.
    0089dace
To find the state of this project's repository at the time of any of these versions, check out the tags.