aboutsummaryrefslogtreecommitdiffstats
path: root/core/mixer/mixer_sse.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2023-02-10 02:24:59 -0800
committerChris Robinson <[email protected]>2023-02-10 02:24:59 -0800
commitca419e2966f43ccec5a023afc206972ddbf0a137 (patch)
tree939d9a2502d7c32a32513a141ada46ee518f6493 /core/mixer/mixer_sse.cpp
parenteb5e48f133de94e706f67c7d5388e5c45b43f338 (diff)
Assume 'frac' is less than 1
Diffstat (limited to 'core/mixer/mixer_sse.cpp')
-rw-r--r--core/mixer/mixer_sse.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/mixer/mixer_sse.cpp b/core/mixer/mixer_sse.cpp
index e011dfcd..6bbb3d3c 100644
--- a/core/mixer/mixer_sse.cpp
+++ b/core/mixer/mixer_sse.cpp
@@ -157,6 +157,8 @@ template<>
float *Resample_<CubicTag,SSETag>(const InterpState *state, float *RESTRICT src, uint frac,
uint increment, const al::span<float> dst)
{
+ ASSUME(frac < MixerFracOne);
+
const CubicCoefficients *RESTRICT filter = al::assume_aligned<16>(state->cubic.filter);
src -= 1;
@@ -193,6 +195,7 @@ float *Resample_<BSincTag,SSETag>(const InterpState *state, float *RESTRICT src,
const __m128 sf4{_mm_set1_ps(state->bsinc.sf)};
const size_t m{state->bsinc.m};
ASSUME(m > 0);
+ ASSUME(frac < MixerFracOne);
src -= state->bsinc.l;
for(float &out_sample : dst)
@@ -240,6 +243,7 @@ float *Resample_<FastBSincTag,SSETag>(const InterpState *state, float *RESTRICT
const float *const filter{state->bsinc.filter};
const size_t m{state->bsinc.m};
ASSUME(m > 0);
+ ASSUME(frac < MixerFracOne);
src -= state->bsinc.l;
for(float &out_sample : dst)