[llvm-commits] [llvm] r150060 - in /llvm/trunk: include/llvm/IntrinsicsX86.td lib/Target/X86/X86ISelLowering.cpp lib/Target/X86/X86InstrSSE.td

Chris Lattner clattner at apple.com
Thu Feb 9 02:00:10 PST 2012


On Feb 9, 2012, at 1:50 AM, Duncan Sands wrote:

> Hi Chris,
> 
>>>> That's correct, but what I did is no different than what is already done for
>>>> pshufd, shufps/pd, punpckl*, punpckh*, unpcklps/pd, unpckhps/pd, pshuflw,
>>>> pshufhw, etc.
>>> 
>>> was it really a good idea to remove them?  You could have had clang support them
>>> at little cost, maintaining GCC compatibility.
>> 
>> Hi Duncan,
>> 
>> I haven't been following the whole thread, but yes, we really do want to remove intrinsics that are redundant with core IR instructions.  In reality, what we wanted is for them never to be added in the first place :).  Over time, we hope that LLVM IR becomes more expressive, and as such it will increasingly overlap with things that are currently intrinsics.  Another one that is on the chopping block at some point is the half-float conversion intrinsics, which are now redundant with casts to the native half-float type.
> 
> I wasn't referring to removal of the intrinsics, I meant removing clang support
> for builtin_ia32_pshufd etc: clang could continue to support them by expanding
> them into generic LLVM IR.

The vector __builtin's are considered an internal implementation detail of the *intrin.h files, and clang's work completely differently than GCC's.  We don't try to support uses of the builtins directly.  See also:
http://clang.llvm.org/compatibility.html#vector_builtins

-Chris



More information about the llvm-commits mailing list