-
Notifications
You must be signed in to change notification settings - Fork 31
Open
Labels
enhancementNew feature or requestNew feature or requestquestionFurther information is requestedFurther information is requested
Description
Issue type: Error
While utilizing the Right shift and Left shift bitwise operators, I'm getting an error:
/home/nk/opt/nsimd/include/nsimd/cxx_adv_api_functions.hpp:998:16: error: no matching function for call to ‘shr(const simd_vector&, int&, float, nsimd::cpu)’
998 | ret.car = shr(a0.car, a1, T(), SimdExt());
Reproducing the error
Here is the minimal program to reproduce the issue:
#include <iostream>
#include <nsimd/nsimd-all.hpp>
int main()
{
nsimd::pack<float> f(42.0f);
nsimd::pack<float> f2 = nsimd::shr(f2, 1);
std::cout << f2 << std::endl;
return 0;
}
Is there something I'm doing wrong?
Expected behavior
Essentially I wish to change a simd vector, say [1, 2, 3, 4] to look like [0,1,2,3] using the right shift operation.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestquestionFurther information is requestedFurther information is requested