Commit a3c17f56 authored by Berenger Bramas's avatar Berenger Bramas

Update vec classes -- use splat(0) instead of xor

parent 9cc20435
......@@ -61,14 +61,12 @@ public:
// Bool data type compatibility
inline explicit InaVecMaskALTIVEC(const bool inBool){
const __vector __bool long long tmpMaskFF = reinterpret_cast<__vector __bool long long>(vec_splats(0xFFFFFFFFFFFFFFFFUL));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool long long>(vec_xor(reinterpret_cast<__vector unsigned int>(mask),
reinterpret_cast<__vector unsigned int>(mask))));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool long long>(vec_splats(0x0UL)));
}
inline InaVecMaskALTIVEC& operator=(const bool inBool){
const __vector __bool long long tmpMaskFF = reinterpret_cast<__vector __bool long long>(vec_splats(0xFFFFFFFFFFFFFFFFUL));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool long long>(vec_xor(reinterpret_cast<__vector unsigned int>(mask),
reinterpret_cast<__vector unsigned int>(mask))));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool long long>(vec_splats(0x0UL)));
return (*this);
}
......
......@@ -60,12 +60,12 @@ public:
// Bool data type compatibility
inline explicit InaVecMaskALTIVEC(const bool inBool){
const __vector __bool int tmpMaskFF = reinterpret_cast<__vector __bool int>(vec_splats(0xFFFFFFFFU));
mask = (inBool? tmpMaskFF : vec_xor(tmpMaskFF, tmpMaskFF));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool int>(vec_splats(0x0U)));
}
inline InaVecMaskALTIVEC& operator=(const bool inBool){
const __vector __bool int tmpMaskFF = reinterpret_cast<__vector __bool int>(vec_splats(0xFFFFFFFFU));
mask = (inBool? tmpMaskFF : vec_xor(tmpMaskFF, tmpMaskFF));
mask = (inBool? tmpMaskFF : reinterpret_cast<__vector __bool int>(vec_splats(0x0U)));
return (*this);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment