Commit 05db906e authored by Eero Häkkinen's avatar Eero Häkkinen Committed by Commit Bot

Increase AudioArray alignment for better AVX optimization

This CL increases AudioArray alignment on x86 family architectures so
that blink::VectorMath functions can better utilize AVX optimizations.

Bug: 778262
Change-Id: Ibe94130ba0d0223342ae25f844c69767194370e9
Reviewed-on: https://chromium-review.googlesource.com/738239Reviewed-by: default avatarRaymond Toy <rtoy@chromium.org>
Commit-Queue: Eero Häkkinen <eero.hakkinen@intel.com>
Cr-Commit-Position: refs/heads/master@{#537259}
parent d9a63882
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
#define AudioArray_h #define AudioArray_h
#include <string.h> #include <string.h>
#include "build/build_config.h"
#include "platform/wtf/Allocator.h" #include "platform/wtf/Allocator.h"
#include "platform/wtf/Noncopyable.h" #include "platform/wtf/Noncopyable.h"
#include "platform/wtf/allocator/Partitions.h" #include "platform/wtf/allocator/Partitions.h"
...@@ -61,7 +62,8 @@ class AudioArray { ...@@ -61,7 +62,8 @@ class AudioArray {
unsigned initial_size = sizeof(T) * n; unsigned initial_size = sizeof(T) * n;
#if defined(WTF_USE_WEBAUDIO_FFMPEG) || defined(WTF_USE_WEBAUDIO_OPENMAX_DL_FFT) #if defined(ARCH_CPU_X86_FAMILY) || defined(WTF_USE_WEBAUDIO_FFMPEG) || \
defined(WTF_USE_WEBAUDIO_OPENMAX_DL_FFT)
const size_t kAlignment = 32; const size_t kAlignment = 32;
#else #else
const size_t kAlignment = 16; const size_t kAlignment = 16;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment