mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-30 08:53:08 +01:00
AVX/SSE compatibility
This fixes symbol mangle for window builds, and offers backwards compatibility with older systems where the inline _mm256_cvtss_f32 is not defined in avxintrin.h
This commit is contained in:
parent
b0707b812d
commit
01dbbb86c3
2 changed files with 7 additions and 2 deletions
|
|
@ -40,10 +40,15 @@ extern "C" {
|
|||
LIBARDOUR_API void x86_sse_avx_mix_buffers_with_gain(float * dst, const float * src, uint32_t nframes, float gain);
|
||||
LIBARDOUR_API void x86_sse_avx_mix_buffers_no_gain (float * dst, const float * src, uint32_t nframes);
|
||||
LIBARDOUR_API void x86_sse_avx_copy_vector (float * dst, const float * src, uint32_t nframes);
|
||||
#ifndef PLATFORM_WINDOWS
|
||||
LIBARDOUR_API void x86_sse_avx_find_peaks (const float * buf, uint32_t nsamples, float *min, float *max);
|
||||
#endif
|
||||
}
|
||||
|
||||
LIBARDOUR_API void x86_sse_find_peaks (const float * buf, uint32_t nsamples, float *min, float *max);
|
||||
LIBARDOUR_API void x86_sse_find_peaks (const float * buf, uint32_t nsamples, float *min, float *max);
|
||||
#ifdef PLATFORM_WINDOWS
|
||||
LIBARDOUR_API void x86_sse_avx_find_peaks (const float * buf, uint32_t nsamples, float *min, float *max);
|
||||
#endif
|
||||
|
||||
/* debug wrappers for SSE functions */
|
||||
|
||||
|
|
|
|||
|
|
@ -137,7 +137,7 @@ x86_sse_avx_compute_peak(const float *src, uint32_t nframes, float current)
|
|||
// zero upper 128 bit of 256 bit ymm register to avoid penalties using non-AVX instructions
|
||||
_mm256_zeroupper();
|
||||
|
||||
return _mm256_cvtss_f32(vcurrent);
|
||||
return vcurrent[0]; // _mm256_cvtss_f32
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue