This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Help with 'ev_sl' PowerPC SPE Intrinsic
- From: Rohit Arul Raj <rohitarulraj at gmail dot com>
- To: gcc <gcc at gcc dot gnu dot org>
- Date: Tue, 15 May 2012 17:56:03 +0530
- Subject: Help with 'ev_sl' PowerPC SPE Intrinsic
Hello All,
I need some help regarding implementation of one of the SPE instructions.
I am planning to implement 'evsl' instrinsic.
d = __ev_sl (a,b) : The value in parameter 'a' is shifted left by no.
of ?bit positions specified in parameter 'b', filling vacated bit
positions with zeros, and the result is placed into parameter d.
My question: Is it better to have parameter 'b' of single scalar type
[int a] or vector type [__ev64_u64__ g = { 3 } ]?
Looking at _ev_slb, _ev_slh, _ev_slw, where a single scalar type will
not work since the shift amounts are carried by a "vector" of bytes,
half-words, and words respectively, for uniformity can we consider
64-bit shift as similar, a "vector" of one shift amount?
Thanks in advance.
Regards,
Rohit