Enabling building with NEON on ARM64
This patch enables NEON on ARM64 platform. Passed building both on Android ARMv7 and Android ARM64. BUG=3580 R=andrew@webrtc.org, jridges@masque.com Review URL: https://webrtc-codereview.appspot.com/25069004 Patch from Zhongwei Yao <zhongwei.yao@arm.com>. git-svn-id: http://webrtc.googlecode.com/svn/trunk@7751 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -378,7 +378,8 @@ static void ResetAdaptiveChannelC(AecmCore_t* aecm)
|
||||
}
|
||||
|
||||
// Initialize function pointers for ARM Neon platform.
|
||||
#if (defined WEBRTC_DETECT_ARM_NEON || defined WEBRTC_ARCH_ARM_NEON)
|
||||
#if (defined WEBRTC_DETECT_ARM_NEON || defined WEBRTC_ARCH_ARM_NEON || \
|
||||
defined WEBRTC_ARCH_ARM64_NEON)
|
||||
static void WebRtcAecm_InitNeon(void)
|
||||
{
|
||||
WebRtcAecm_StoreAdaptiveChannel = WebRtcAecm_StoreAdaptiveChannelNeon;
|
||||
@ -532,7 +533,7 @@ int WebRtcAecm_InitCore(AecmCore_t * const aecm, int samplingFreq)
|
||||
{
|
||||
WebRtcAecm_InitNeon();
|
||||
}
|
||||
#elif defined(WEBRTC_ARCH_ARM_NEON)
|
||||
#elif defined(WEBRTC_ARCH_ARM_NEON) || defined(WEBRTC_ARCH_ARM64_NEON)
|
||||
WebRtcAecm_InitNeon();
|
||||
#endif
|
||||
|
||||
|
||||
@ -416,7 +416,8 @@ extern ResetAdaptiveChannel WebRtcAecm_ResetAdaptiveChannel;
|
||||
// For the above function pointers, functions for generic platforms are declared
|
||||
// and defined as static in file aecm_core.c, while those for ARM Neon platforms
|
||||
// are declared below and defined in file aecm_core_neon.s.
|
||||
#if (defined WEBRTC_DETECT_ARM_NEON) || defined (WEBRTC_ARCH_ARM_NEON)
|
||||
#if (defined WEBRTC_DETECT_ARM_NEON) || defined (WEBRTC_ARCH_ARM_NEON) || \
|
||||
defined (WEBRTC_ARCH_ARM64_NEON)
|
||||
void WebRtcAecm_CalcLinearEnergiesNeon(AecmCore_t* aecm,
|
||||
const uint16_t* far_spectrum,
|
||||
int32_t* echo_est,
|
||||
|
||||
@ -43,6 +43,7 @@ static const ALIGN8_BEG int16_t kSqrtHanningReversed[] ALIGN8_END = {
|
||||
3172, 2780, 2386, 1990, 1594, 1196, 798, 399
|
||||
};
|
||||
|
||||
#ifndef WEBRTC_ARCH_ARM64_NEON
|
||||
void WebRtcAecm_WindowAndFFTNeon(AecmCore_t* aecm,
|
||||
int16_t* fft,
|
||||
const int16_t* time_signal,
|
||||
@ -226,6 +227,7 @@ void WebRtcAecm_InverseFFTAndWindowNeon(AecmCore_t* aecm,
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif //WEBRTC_ARCH_ARM64_NEON
|
||||
|
||||
static inline void AddLanes(uint32_t* ptr, uint32x4_t v) {
|
||||
#if defined(__aarch64__)
|
||||
|
||||
Reference in New Issue
Block a user