summaryrefslogtreecommitdiffstats
path: root/src/corelib/global/qendian.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-20 11:42:50 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-21 21:15:17 +0200
commitff776a3059b25f8dd3c3abbd6aa8ffa95ec9cf7a (patch)
treeae627fb3b96e7675c22219747d0baf1cd29da013 /src/corelib/global/qendian.cpp
parent33617c03a47c930b8abe6ad3c583bf4251845f24 (diff)
Whitespace cleanup in corelib/global
Change-Id: I087d7d949cfd43e48e8a008621a4eeaa9d104ceb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/global/qendian.cpp')
-rw-r--r--src/corelib/global/qendian.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/corelib/global/qendian.cpp b/src/corelib/global/qendian.cpp
index c69572cccf..cc9158e34d 100644
--- a/src/corelib/global/qendian.cpp
+++ b/src/corelib/global/qendian.cpp
@@ -815,7 +815,7 @@ size_t simdSwapLoop(const uchar *src, size_t bytes, uchar *dst) noexcept
size_t i = sseSwapLoop(src, bytes, dst, shuffleMaskPtr);
// epilogue
- for (size_t _i = 0 ; i < bytes && _i < sizeof(__m128i); i += sizeof(T), _i += sizeof(T))
+ for (size_t _i = 0; i < bytes && _i < sizeof(__m128i); i += sizeof(T), _i += sizeof(T))
qbswap(qFromUnaligned<T>(src + i), dst + i);
// return the total, so the bswapLoop below does nothing
@@ -886,12 +886,13 @@ void *bswapLoop(const uchar *src, size_t n, uchar *dst) noexcept
size_t i = simdSwapLoop<T>(src, n, dst);
- for ( ; i < n; i += sizeof(T))
+ for (; i < n; i += sizeof(T))
qbswap(qFromUnaligned<T>(src + i), dst + i);
return dst + i;
}
-template <> void *qbswap<2>(const void *source, qsizetype n, void *dest) noexcept
+template<>
+void *qbswap<2>(const void *source, qsizetype n, void *dest) noexcept
{
const uchar *src = reinterpret_cast<const uchar *>(source);
uchar *dst = reinterpret_cast<uchar *>(dest);
@@ -899,7 +900,8 @@ template <> void *qbswap<2>(const void *source, qsizetype n, void *dest) noexcep
return bswapLoop<quint16>(src, n << 1, dst);
}
-template <> void *qbswap<4>(const void *source, qsizetype n, void *dest) noexcept
+template<>
+void *qbswap<4>(const void *source, qsizetype n, void *dest) noexcept
{
const uchar *src = reinterpret_cast<const uchar *>(source);
uchar *dst = reinterpret_cast<uchar *>(dest);
@@ -907,7 +909,8 @@ template <> void *qbswap<4>(const void *source, qsizetype n, void *dest) noexcep
return bswapLoop<quint32>(src, n << 2, dst);
}
-template <> void *qbswap<8>(const void *source, qsizetype n, void *dest) noexcept
+template<>
+void *qbswap<8>(const void *source, qsizetype n, void *dest) noexcept
{
const uchar *src = reinterpret_cast<const uchar *>(source);
uchar *dst = reinterpret_cast<uchar *>(dest);