X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=app%2Ftest%2Ftest_xmmt_ops.h;h=42174d2c92cbeafb31fc45d77c41be4b4eb867b7;hb=0f6f219e7919c988675f4695485334530af0a6ca;hp=de9c16fee928487bc5d09d88a8d3d2655bfa442b;hpb=cbc2f1dccfbae4226839257b8cdf297457d6a674;p=dpdk.git diff --git a/app/test/test_xmmt_ops.h b/app/test/test_xmmt_ops.h index de9c16fee9..42174d2c92 100644 --- a/app/test/test_xmmt_ops.h +++ b/app/test/test_xmmt_ops.h @@ -62,6 +62,22 @@ vect_set_epi32(int i3, int i2, int i1, int i0) /* sets the 4 signed 32-bit integer values and returns the xmm_t variable */ #define vect_set_epi32(i3, i2, i1, i0) _mm_set_epi32(i3, i2, i1, i0) +#elif defined(RTE_ARCH_PPC_64) + +/* vect_* abstraction implementation using ALTIVEC */ + +/* loads the xmm_t value from address p(does not need to be 16-byte aligned)*/ +#define vect_loadu_sil128(p) vec_ld(0, p) + +/* sets the 4 signed 32-bit integer values and returns the xmm_t variable */ +static inline xmm_t __attribute__((always_inline)) +vect_set_epi32(int i3, int i2, int i1, int i0) +{ + xmm_t data = (xmm_t){i0, i1, i2, i3}; + + return data; +} + #endif #endif /* _TEST_XMMT_OPS_H_ */