Created
June 23, 2017 08:41
-
-
Save DavidPfander-UniStuttgart/ee67ae5ed947118e5ef50afdd7d2c840 to your computer and use it in GitHub Desktop.
simd vector casting
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using simd_vector = typename Vc::datapar<double, Vc::datapar_abi::fixed_size<8>>; | |
using int_simd_vector = typename Vc::datapar<int32_t, Vc::datapar_abi::fixed_size<8>>; | |
... | |
const int_simd_vector theta_c_rec_squared_int = | |
detail::distance_squared(cell_index_coarse, interaction_partner_index_coarse); | |
const simd_vector theta_c_rec_squared = | |
Vc::static_datapar_cast<double>(theta_c_rec_squared_int); | |
compile log: | |
... | |
/usr/include/c++/6/type_traits: In instantiation of ‘struct std::make_unsigned<double>’: | |
/home/pfandedd/Vc_install/include/Vc/detail/synopsis.h:269:12: required from ‘auto Vc::v2::static_datapar_cast(const Vc::v2::datapar<T, A0>&) [with T = double; U = int; A = Vc::v2::datapar_abi::fixed_size<8>]’ | |
/home/pfandedd/git/octotiger/src/kernels/m2m_kernel_blocked_interaction.cpp:107:72: required from here | |
/usr/include/c++/6/type_traits:1831:62: error: invalid use of incomplete type ‘class std::__make_unsigned_selector<double, false, false>’ | |
{ typedef typename __make_unsigned_selector<_Tp>::__type type; }; | |
^~~~ | |
/usr/include/c++/6/type_traits:1788:11: note: declaration of ‘class std::__make_unsigned_selector<double, false, false>’ | |
class __make_unsigned_selector; | |
^~~~~~~~~~~~~~~~~~~~~~~~ | |
/home/pfandedd/git/octotiger/src/kernels/m2m_kernel_blocked_interaction.cpp: In member function ‘void octotiger::fmm::m2m_kernel::blocked_interaction(const octotiger::fmm::multiindex<>&, int64_t, const octotiger::fmm::multiindex<Vc::v2::datapar<int, Vc::v2::datapar_abi::fixed_size<8> > >&, const octotiger::fmm::multiindex<>&, int64_t, const std::vector<octotiger::fmm::multiindex<> >&, size_t)’: | |
/home/pfandedd/git/octotiger/src/kernels/m2m_kernel_blocked_interaction.cpp:107:48: error: conversion from ‘void’ to non-scalar type ‘const simd_vector {aka const Vc::v2::datapar<double, Vc::v2::datapar_abi::fixed_size<8> >}’ requested | |
Vc::static_datapar_cast<double>(theta_c_rec_squared_int); | |
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~ | |
CMakeFiles/octotiger_exe.dir/build.make:974: recipe for target 'CMakeFiles/octotiger_exe.dir/src/kernels/m2m_kernel_blocked_interaction.cpp.o' failed | |
make[2]: *** [CMakeFiles/octotiger_exe.dir/src/kernels/m2m_kernel_blocked_interaction.cpp.o] Error 1 | |
make[2]: Leaving directory '/home/pfandedd/git/octotiger/build_with_symbols' | |
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/octotiger_exe.dir/all' failed | |
make[1]: *** [CMakeFiles/octotiger_exe.dir/all] Error 2 | |
make[1]: Leaving directory '/home/pfandedd/git/octotiger/build_with_symbols' | |
Makefile:127: recipe for target 'all' failed | |
make: *** [all] Error 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment