Skip to content
Snippets Groups Projects
Commit f57b3cdb authored by Martin Larralde's avatar Martin Larralde
Browse files

Make AVX2 implementation of `score_into` with `gather` more generic

parent ff811f37
No related branches found
No related tags found
No related merge requests found
...@@ -8,6 +8,7 @@ use std::ops::Range; ...@@ -8,6 +8,7 @@ use std::ops::Range;
use typenum::consts::U32; use typenum::consts::U32;
use typenum::consts::U5; use typenum::consts::U5;
use typenum::consts::U8;
use typenum::IsLessOrEqual; use typenum::IsLessOrEqual;
use typenum::NonZero; use typenum::NonZero;
use typenum::Unsigned; use typenum::Unsigned;
...@@ -101,8 +102,8 @@ unsafe fn score_avx2_permute<A>( ...@@ -101,8 +102,8 @@ unsafe fn score_avx2_permute<A>(
scores: &mut StripedScores<<Avx2 as Backend>::LANES>, scores: &mut StripedScores<<Avx2 as Backend>::LANES>,
) where ) where
A: Alphabet, A: Alphabet,
<A as Alphabet>::K: IsLessOrEqual<U5>, <A as Alphabet>::K: IsLessOrEqual<U8>,
<<A as Alphabet>::K as IsLessOrEqual<U5>>::Output: NonZero, <<A as Alphabet>::K as IsLessOrEqual<U8>>::Output: NonZero,
{ {
let data = scores.matrix_mut(); let data = scores.matrix_mut();
debug_assert!(data.rows() > 0); debug_assert!(data.rows() > 0);
...@@ -613,8 +614,8 @@ impl Avx2 { ...@@ -613,8 +614,8 @@ impl Avx2 {
scores: &mut StripedScores<<Avx2 as Backend>::LANES>, scores: &mut StripedScores<<Avx2 as Backend>::LANES>,
) where ) where
A: Alphabet, A: Alphabet,
<A as Alphabet>::K: IsLessOrEqual<U5>, <A as Alphabet>::K: IsLessOrEqual<U8>,
<<A as Alphabet>::K as IsLessOrEqual<U5>>::Output: NonZero, <<A as Alphabet>::K as IsLessOrEqual<U8>>::Output: NonZero,
S: AsRef<StripedSequence<A, <Avx2 as Backend>::LANES>>, S: AsRef<StripedSequence<A, <Avx2 as Backend>::LANES>>,
M: AsRef<ScoringMatrix<A>>, M: AsRef<ScoringMatrix<A>>,
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment