23 |
#ifndef __LS_GIG_SYNTHESIZER_H__ |
#ifndef __LS_GIG_SYNTHESIZER_H__ |
24 |
#define __LS_GIG_SYNTHESIZER_H__ |
#define __LS_GIG_SYNTHESIZER_H__ |
25 |
|
|
26 |
|
#include "../../common/global.h" |
27 |
#include "../../common/RTMath.h" |
#include "../../common/RTMath.h" |
28 |
#include "../common/Resampler.h" |
#include "../common/Resampler.h" |
29 |
#include "../common/BiquadFilter.h" |
#include "../common/BiquadFilter.h" |
153 |
case CPP: { |
case CPP: { |
154 |
return uint((LoopEnd - *((double *)Pos)) / Pitch); |
return uint((LoopEnd - *((double *)Pos)) / Pitch); |
155 |
} |
} |
156 |
|
#if ARCH_X86 |
157 |
case ASM_X86_MMX_SSE: { |
case ASM_X86_MMX_SSE: { |
158 |
int result; |
int result; |
159 |
__asm__ __volatile__ ( |
__asm__ __volatile__ ( |
168 |
); |
); |
169 |
return result; |
return result; |
170 |
} |
} |
171 |
|
#endif // ARCH_X86 |
172 |
} |
} |
173 |
} |
} |
174 |
|
|
181 |
*Pos = fmod(*Pos - LoopEnd, LoopSize) + LoopStart; |
*Pos = fmod(*Pos - LoopEnd, LoopSize) + LoopStart; |
182 |
return 1; |
return 1; |
183 |
} |
} |
184 |
|
#if ARCH_X86 |
185 |
case ASM_X86_MMX_SSE: { |
case ASM_X86_MMX_SSE: { |
186 |
int result; |
int result; |
187 |
__asm__ __volatile__ ( |
__asm__ __volatile__ ( |
214 |
); |
); |
215 |
return result; |
return result; |
216 |
} |
} |
217 |
|
#endif // ARCH_X86 |
218 |
} |
} |
219 |
} |
} |
220 |
|
|
245 |
} |
} |
246 |
break; |
break; |
247 |
} |
} |
248 |
|
#if ARCH_X86 |
249 |
// Assembly optimization using the MMX & SSE(1) instruction set (thus only for x86) |
// Assembly optimization using the MMX & SSE(1) instruction set (thus only for x86) |
250 |
case ASM_X86_MMX_SSE: { |
case ASM_X86_MMX_SSE: { |
251 |
const int ii = i & 0xfffffffc; |
const int ii = i & 0xfffffffc; |
331 |
"r" (&pOutR[ii]) /* %1 - must be 16 byte aligned ! */ |
"r" (&pOutR[ii]) /* %1 - must be 16 byte aligned ! */ |
332 |
); |
); |
333 |
} |
} |
334 |
|
#endif // ARCH_X86 |
335 |
} |
} |
336 |
} |
} |
337 |
}; |
}; |