[X86] Remove avx512 isel patterns for fpextend+load. Prefer to only match fp extloads...
authorCraig Topper <craig.topper@intel.com>
Fri, 31 May 2019 06:21:53 +0000 (06:21 +0000)
committerCraig Topper <craig.topper@intel.com>
Fri, 31 May 2019 06:21:53 +0000 (06:21 +0000)
commitb79cc5f8024447ab5235a62192dd1425052f5b7c
treea0a4b6bbb89779f2d162a8e88abcabfc7b29e6b4
parent73b07284df2760433da1294f445ea6f8f8eabce9
[X86] Remove avx512 isel patterns for fpextend+load. Prefer to only match fp extloads instead.

DAG combine will usually fold fpextend+load to an fp extload anyway. So the
256 and 512 patterns were probably unnecessary. The 128 bit pattern was special
in that it looked for a v4f32 load, but then used it in an instruction that
only loads 64-bits. This is bad if the load happens to be volatile. We could
probably make the patterns volatile aware, but that's more work for something
that's probably rare. The peephole pass might kick in and save us anyway. We
might also be able to fix this with some additional DAG combines.

This also adds patterns for vselect+extload to enabled masked vcvtps2pd to be
used. Previously we looked for the unlikely vselect+fpextend+load.

llvm-svn: 362199
llvm/lib/Target/X86/X86InstrAVX512.td
llvm/test/CodeGen/X86/avx512-cvt.ll
llvm/test/CodeGen/X86/vec_fpext.ll