DU Results -

Source patches

du6bitcount.hpp

8c8
< #include <immintrin.h>
---
> #include <nmmintrin.h>
206c206,209
<         return _mm_set1_epi64x( static_cast<std::uint64_t>(-1LL));
---
>         __m128i n;
>         for (std::size_t i = 0; i < packs64; ++i)
>             n.m128i_u64[i] = static_cast<std::uint64_t>(-1LL);
>         return n;
211c214
<         return reinterpret_cast<const std::uint8_t*>(&vec)[index];
---
>         return vec.m128i_u8[index];
216c219
<         return reinterpret_cast<const std::uint64_t*>(&vec)[index];
---
>         return vec.m128i_u64[index];
221c224
<         return reinterpret_cast<std::uint64_t*>(&vec)[index];
---
>         return vec.m128i_u64[index];
226,227c229,232
<         auto r = _mm_cmpeq_epi64(v1,v2);
< 	return _mm_test_all_ones(r);
---
>         bool res = true;
>         for (std::size_t i = 0; i < packs64; ++i)
>             res = res && v1.m128i_u64[i] == v2.m128i_u64[i];
>         return res;
230c235
<     static __m128i or_(__m128i v1, __m128i v2)
---
>     static __m128i or(__m128i v1, __m128i v2)
235c240
<     static __m128i and_(__m128i v1, __m128i v2)
---
>     static __m128i and(__m128i v1, __m128i v2)
240c245
<     static __m128i xor_(__m128i v1, __m128i v2)
---
>     static __m128i xor(__m128i v1, __m128i v2)
260c265,268
<         return _mm256_set1_epi64x( static_cast<std::uint64_t>(-1LL));
---
>         __m256i n;
>         for (std::size_t i = 0; i < packs64; ++i)
>             n.m256i_u64[i] = static_cast<std::uint64_t>(-1LL);
>         return n;
265c273
<         return reinterpret_cast<const std::uint8_t*>(&vec)[index];
---
>         return vec.m256i_u8[index];
270c278
<         return reinterpret_cast<std::uint64_t*>(&vec)[index];
---
>         return vec.m256i_u64[index];
275c283
<         return reinterpret_cast<const std::uint64_t*>(&vec)[index];
---
>         return vec.m256i_u64[index];
280,281c288,291
<         auto r = _mm256_cmpeq_epi64(v1,v2);
< 	return _mm256_movemask_epi8(r) == 0xFFFFFFFF;
---
>         bool res = true;
>         for (std::size_t i = 0; i < packs64; ++i)
>             res = res && v1.m256i_u64[i] == v2.m256i_u64[i];
>         return res;
284c294
<     static __m256i or_(__m256i v1, __m256i v2)
---
>     static __m256i or(__m256i v1, __m256i v2)
289c299
<     static __m256i and_(__m256i v1, __m256i v2)
---
>     static __m256i and(__m256i v1, __m256i v2)
294c304
<     static __m256i xor_(__m256i v1, __m256i v2)
---
>     static __m256i xor(__m256i v1, __m256i v2)
344c354
<     static __m512i or_(__m512i v1, __m512i v2)
---
>     static __m512i or(__m512i v1, __m512i v2)
349c359
<     static __m512i and_(__m512i v1, __m512i v2)
---
>     static __m512i and(__m512i v1, __m512i v2)
354c364
<     static __m512i xor_(__m512i v1, __m512i v2)
---
>     static __m512i xor(__m512i v1, __m512i v2)
398c408
<             total_simd = simd_traits_t::or_(total_simd, m_storage[i]);
---
>             total_simd = simd_traits_t::or(total_simd, m_storage[i]);
400,401c410
<         std::size_t i = 0; 
<         for (; i < remaining_simd_in_last(); ++i)
---
>         for (std::size_t i = 0; i < remaining_simd_in_last(); ++i)
426c435
<             m_storage[i] = simd_traits_t::xor_(a.m_storage[i], neg_one);
---
>             m_storage[i] = simd_traits_t::xor(a.m_storage[i], neg_one);
442c451
<             m_storage[i] = simd_traits_t::and_(a.m_storage[i], b.m_storage[i]);
---
>             m_storage[i] = simd_traits_t::and(a.m_storage[i], b.m_storage[i]);
459c468
<             m_storage[i] = simd_traits_t::or_(a.m_storage[i], b.m_storage[i]);
---
>             m_storage[i] = simd_traits_t::or(a.m_storage[i], b.m_storage[i]);
533c542
< #endif
---
> #endif
\ No newline at end of file

Flex error reports

C++ error reports

du6bitcount.cpp

In file included from ../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.cpp:1:0:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static __m512i simd_traits<__vector(8) long long int>::neg_one()’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:317:15: error: request for member ‘m512i_u64’ in ‘n’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             n.m512i_u64[i] = static_cast<std::uint64_t>(-1LL);
               ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static const uint8_t& simd_traits<__vector(8) long long int>::get_scalar8(const __m256i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:323:20: error: request for member ‘m256i_u8’ in ‘vec’, which is of non-class type ‘const __m256i {aka const __vector(4) long long int}’
         return vec.m256i_u8[index];
                    ^~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static uint64_t& simd_traits<__vector(8) long long int>::get_scalar64(__m512i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:328:20: error: request for member ‘m512i_u64’ in ‘vec’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
         return vec.m512i_u64[index];
                    ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static const uint64_t& simd_traits<__vector(8) long long int>::get_scalar64(const __m512i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:333:20: error: request for member ‘m512i_u64’ in ‘vec’, which is of non-class type ‘const __m512i {aka const __vector(8) long long int}’
         return vec.m512i_u64[index];
                    ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static bool simd_traits<__vector(8) long long int>::equals(__m512i, __m512i)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:340:29: error: request for member ‘m512i_u64’ in ‘v1’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             res = res && v1.m512i_u64[i] == v2.m512i_u64[i];
                             ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:340:48: error: request for member ‘m512i_u64’ in ‘v2’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             res = res && v1.m512i_u64[i] == v2.m512i_u64[i];
                                                ^~~~~~~~~

du6main.cpp

In file included from du6main.cpp:5:0:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static __m512i simd_traits<__vector(8) long long int>::neg_one()’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:317:15: error: request for member ‘m512i_u64’ in ‘n’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             n.m512i_u64[i] = static_cast<std::uint64_t>(-1LL);
               ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static const uint8_t& simd_traits<__vector(8) long long int>::get_scalar8(const __m256i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:323:20: error: request for member ‘m256i_u8’ in ‘vec’, which is of non-class type ‘const __m256i {aka const __vector(4) long long int}’
         return vec.m256i_u8[index];
                    ^~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static uint64_t& simd_traits<__vector(8) long long int>::get_scalar64(__m512i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:328:20: error: request for member ‘m512i_u64’ in ‘vec’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
         return vec.m512i_u64[index];
                    ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static const uint64_t& simd_traits<__vector(8) long long int>::get_scalar64(const __m512i&, std::size_t)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:333:20: error: request for member ‘m512i_u64’ in ‘vec’, which is of non-class type ‘const __m512i {aka const __vector(8) long long int}’
         return vec.m512i_u64[index];
                    ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp: In static member function ‘static bool simd_traits<__vector(8) long long int>::equals(__m512i, __m512i)’:
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:340:29: error: request for member ‘m512i_u64’ in ‘v1’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             res = res && v1.m512i_u64[i] == v2.m512i_u64[i];
                             ^~~~~~~~~
../../../studenti/20162/Kliber_Filip_72976743/du6bitcount.hpp:340:48: error: request for member ‘m512i_u64’ in ‘v2’, which is of non-class type ‘__m512i {aka __vector(8) long long int}’
             res = res && v1.m512i_u64[i] == v2.m512i_u64[i];
                                                ^~~~~~~~~

Linker error reports

du6.cpp

Something is missing: ../../../studenti/20162/__tmp6specific/phi01/Kliber_Filip_72976743/du6bitcount.o ../../../studenti/20162/__tmp6specific/phi01/Kliber_Filip_72976743/du6main.o

Run output diffs

empty.in

Something is missing: ../../../studenti/20162/__tmp6specific/phi01/Kliber_Filip_72976743/du6

empty

Something is missing: ../../../studenti/20162/__out6specific/phi01/Kliber_Filip_72976743/empty.err