1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-26 14:33:02 +02:00
llvm-mirror/lib
Adam Nemet 65c87794ae [VectorLegalizer/X86] Don't unvectorize fp_to_uint for v8f32->v8i16
Rather than LegalizeAction::Expand, this needs LegalizeAction::Promote to get
promoted to fp_to_sint v8f32->v8i32.  This is a legal operation on AVX.

For that to work properly, we also need to teach the legalizer about the
specific promotion required here.  The default vector promotion uses
bitcasting to a vector type of the same total size.  We want to promote the
vector element type, effectively widening the operation and then truncating
the result.  This is analogous to the current logic of how int_to_fp is
promoted.

The change also factors out some code from the int_to_fp promotion code to
ValueType::widenIntegerVectorElementType.  This is now shared between
int_to_fp and fp_to_int.

There is no longer need for the custom lowering of fp_to_sint f32->v8i16 in
X86.  It can now go through the new target-independent fp_to_*int promotion
logic.

I also checked that no other target uses Promote for these ops yet, so there
shouldn't be any unexpected change in behavior.

Fixes <rdar://problem/16202247>

llvm-svn: 204058
2014-03-17 17:06:14 +00:00
..
Analysis Consistent use of the noduplicate attribute. 2014-03-17 16:19:07 +00:00
AsmParser Remove the linker_private and linker_private_weak linkages. 2014-03-13 23:18:37 +00:00
Bitcode Support: Make error_category's constructor public 2014-03-15 04:05:59 +00:00
CodeGen [VectorLegalizer/X86] Don't unvectorize fp_to_uint for v8f32->v8i16 2014-03-17 17:06:14 +00:00
DebugInfo Make some assertions on constant expressions static. 2014-03-15 18:47:07 +00:00
ExecutionEngine [C++11] Introduce SectionRef::relocations() to use range-based loops 2014-03-14 14:22:49 +00:00
IR Make some assertions on constant expressions static. 2014-03-15 18:47:07 +00:00
IRReader Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
LineEditor [CMake] Use LINK_LIBS instead of target_link_libraries(). 2014-02-26 06:41:29 +00:00
Linker [Layering] Sink Linker.h into a Linker subdirectory to make it 2014-03-06 03:42:23 +00:00
LTO Remove the linker_private and linker_private_weak linkages. 2014-03-13 23:18:37 +00:00
MC [C++11] Introduce ObjectFile::symbols() to use range-based loops. 2014-03-17 07:28:19 +00:00
Object [C++11] Introduce ObjectFile::symbols() to use range-based loops. 2014-03-17 07:28:19 +00:00
Option Avoid buffer copies when a Twine already is a StringRef. 2013-12-03 18:18:28 +00:00
Support Support: add support to identify WinCOFF/ARM objects 2014-03-13 07:02:35 +00:00
TableGen Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
Target [VectorLegalizer/X86] Don't unvectorize fp_to_uint for v8f32->v8i16 2014-03-17 17:06:14 +00:00
Transforms Consistent use of the noduplicate attribute. 2014-03-17 16:19:07 +00:00
CMakeLists.txt Back out Profile library and dependent commits 2014-03-12 22:00:57 +00:00
LLVMBuild.txt Back out Profile library and dependent commits 2014-03-12 22:00:57 +00:00
Makefile Back out Profile library and dependent commits 2014-03-12 22:00:57 +00:00