llvm-6502/lib
Filipe Cabecinhas c5f611404c Convert some X86 blendv* intrinsics into IR.
Summary:
Implemented an InstCombine transformation that takes a blendv* intrinsic
call and translates it into an IR select, if the mask is constant.

This will eventually get lowered into blends with immediates if possible,
or pblendvb (with an option to further optimize if we can transform the
pblendvb into a blend+immediate instruction, depending on the selector).
It will also enable optimizations by the IR passes, which give up on
sight of the intrinsic.

Both the transformation and the lowering of its result to asm got shiny
new tests.

The transformation is a bit convoluted because of blendvp[sd]'s
definition:

Its mask is a floating point value! This forces us to convert it and get
the highest bit. I suppose this happened because the mask has type
__m128 in Intel's intrinsic and v4sf (for blendps) in gcc's builtin.

I will send an email to llvm-dev to discuss if we want to change this or
not.

Reviewers: grosbach, delena, nadav

Differential Revision: http://reviews.llvm.org/D3859

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@209643 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-27 03:42:20 +00:00
..
Analysis Some cleanup for r209568. 2014-05-26 14:49:46 +00:00
AsmParser [modules] Add module maps for LLVM. These are not quite ready for prime-time 2014-05-21 02:46:14 +00:00
Bitcode Convert a few loops to use ranges. 2014-05-26 13:38:51 +00:00
CodeGen DwarfUnit: Remove some misleading no-op code introduced in r204162. 2014-05-26 05:32:21 +00:00
DebugInfo [modules] Add module maps for LLVM. These are not quite ready for prime-time 2014-05-21 02:46:14 +00:00
ExecutionEngine AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
IR Use existing helper function. 2014-05-26 19:57:55 +00:00
IRReader
LineEditor
Linker
LTO AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
MC AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
Object [YAML] Add an optional argument EnumMask to the yaml::IO::bitSetCase(). 2014-05-23 08:07:09 +00:00
Option
ProfileData
Support Fixup sys::getHostCPUFeatures crypto names so it doesn't clash with kernel headers 2014-05-23 10:14:13 +00:00
TableGen [modules] Add module maps for LLVM. These are not quite ready for prime-time 2014-05-21 02:46:14 +00:00
Target [PPC] Use alias symbols in address computation. 2014-05-26 19:08:19 +00:00
Transforms Convert some X86 blendv* intrinsics into IR. 2014-05-27 03:42:20 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile