From f2118c3b98b2e6cce2cb78ca41977a228a7e3b5f Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli (think)" Date: Wed, 26 Sep 2012 19:07:28 +0200 Subject: crc-dabmod: added AVX FIRFilter implementation that is disabled by default because it's slower than the SSE version. --- src/Buffer.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/Buffer.cpp') diff --git a/src/Buffer.cpp b/src/Buffer.cpp index cef4ad5..7fe0334 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -69,8 +69,10 @@ void Buffer::setLength(size_t len) { if (len > size) { void *tmp = data; - //data = _mm_malloc(len, 16); - data = memalign(16, len); + + /* Align to 32-byte boundary for AVX. */ + data = memalign(32, len); + memcpy(data, tmp, this->len); free(tmp); size = len; -- cgit v1.2.3