In http://reviews.llvm.org/D8301#140042, @craig.topper wrote:

> We've always been sending shuffles to the backend. We just generated the 
> shuffles in CGBuiltin instead of the header.


Hi Craig, yes, I was hoping that this patch would get us to the point that we 
could get rid of even that - or is the CGBuiltin stage good enough do you think?

> I'm not sure I like completely losing the type system on the immediate. 
> Theoretically with the code in CGBuiltin we could at least get a truncation 
> warning if the immediate was larger than a byte. Though I'm not sure that 
> warning is on by default. Really I wish we could check the immediates for 
> illegal values on all of these macros and deliver nice messages to the user. 
> I think gcc does check a lot of them.


Short of adding static_assert I'm not sure of the best way of doing this. We're 
in a position at the moment of having some of the intrinsics already converted 
over to pure __builtin_shufflevector implementations despite having a similar 
problem - the slldq/srldq byte shifts come to mind which are pretty similar to 
alignr.


REPOSITORY
  rL LLVM

http://reviews.llvm.org/D8301

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/



_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to