mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-06-28 16:41:01 +03:00
use the right type of cast
This commit is contained in:
parent
72afe16452
commit
35c0711689
@ -166,7 +166,7 @@ template<>
|
|||||||
template<>
|
template<>
|
||||||
really_inline SuperVector<16>::SuperVector(int64_t const other)
|
really_inline SuperVector<16>::SuperVector(int64_t const other)
|
||||||
{
|
{
|
||||||
u.s64x2[0] = static_cast<int64x2_t>(vec_splats(static_cast<ulong64_t>(other)));
|
u.s64x2[0] = reinterpret_cast<int64x2_t>(vec_splats(static_cast<ulong64_t>(other)));
|
||||||
}
|
}
|
||||||
#if defined(__clang__) && (__clang_major__ >= 15)
|
#if defined(__clang__) && (__clang_major__ >= 15)
|
||||||
#pragma clang diagnostic pop
|
#pragma clang diagnostic pop
|
||||||
@ -176,7 +176,7 @@ template<>
|
|||||||
template<>
|
template<>
|
||||||
really_inline SuperVector<16>::SuperVector(uint64_t const other)
|
really_inline SuperVector<16>::SuperVector(uint64_t const other)
|
||||||
{
|
{
|
||||||
u.u64x2[0] = static_cast<uint64x2_t>(vec_splats(static_cast<ulong64_t>(other)));
|
u.u64x2[0] = reinterpret_cast<uint64x2_t>(vec_splats(static_cast<ulong64_t>(other)));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Constants
|
// Constants
|
||||||
@ -284,7 +284,7 @@ SuperVector<16>::comparemask(void) const {
|
|||||||
uint8x16_t bitmask = vec_gb(u.u8x16[0]);
|
uint8x16_t bitmask = vec_gb(u.u8x16[0]);
|
||||||
bitmask = (uint8x16_t) vec_perm(vec_splat_u8(0), bitmask, perm);
|
bitmask = (uint8x16_t) vec_perm(vec_splat_u8(0), bitmask, perm);
|
||||||
u32 ALIGN_ATTR(16) movemask;
|
u32 ALIGN_ATTR(16) movemask;
|
||||||
vec_ste(static_cast<uint32x4_t>(bitmask), 0, &movemask);
|
vec_ste(reinterpret_cast<uint32x4_t>(bitmask), 0, &movemask);
|
||||||
return movemask;
|
return movemask;
|
||||||
}
|
}
|
||||||
#if defined(__clang__) && (__clang_major__ >= 15)
|
#if defined(__clang__) && (__clang_major__ >= 15)
|
||||||
|
@ -678,7 +678,7 @@ TEST(SimdUtilsTest, movq) {
|
|||||||
#pragma clang diagnostic ignored "-Wdeprecate-lax-vec-conv-all"
|
#pragma clang diagnostic ignored "-Wdeprecate-lax-vec-conv-all"
|
||||||
#endif // defined(__clang__) && (__clang_major__ == 15)
|
#endif // defined(__clang__) && (__clang_major__ == 15)
|
||||||
int64x2_t a = {0x123456789abcdefLL, ~0LL };
|
int64x2_t a = {0x123456789abcdefLL, ~0LL };
|
||||||
simd = static_cast<m128>(a);
|
simd = reinterpret_cast<m128>(a);
|
||||||
#if defined(__clang__) && (__clang_major__ >= 15)
|
#if defined(__clang__) && (__clang_major__ >= 15)
|
||||||
#pragma clang diagnostic pop
|
#pragma clang diagnostic pop
|
||||||
#endif // defined(__clang__) && (__clang_major__ == 15)
|
#endif // defined(__clang__) && (__clang_major__ == 15)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user