Using the have_neon boolean to enable NEON code means we have to either
fully enable it or fully disable it. When using -Dneon=runtime, ideally
only the parts that support runtime checks would be built for NEON, and
those that don't would be built without NEON. Though, there are no
longer any runtime checks for NEON anywhere, so it's equivalent to 'no'
with a warning.
In general, we should use have_* variables to indicate compiler support,
and *_opt options to choose if and how we want to utilize that. Use
neon_opt to control NEON compilation and avoid modifying have_neon which
now would fully refer to compiler support.
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Trying to link both aecm/aecm_core_mips.cc and aecm/aecm_core_c.cc into
the same library results in an error because they both try to implement
webrtc::WebRtcAecm_ProcessBlock():
[306/306] Linking target webrtc/modules/audio_processing/libwebrtc-audio-processing-1.so.3
FAILED: webrtc/modules/audio_processing/libwebrtc-audio-processing-1.so.3
c++ @webrtc/modules/audio_processing/libwebrtc-audio-processing-1.so.3.rsp
/usr/bin/ld: webrtc/modules/audio_processing/libwebrtc-audio-processing-1.so.3.p/aecm_aecm_core_mips.cc.o: in function `webrtc::WebRtcAecm_ProcessBlock(webrtc::AecmCore*, short const*, short const*, short const*, short*)':
[...]/webrtc/modules/audio_processing/aecm/aecm_core_mips.cc:934: multiple definition of `webrtc::WebRtcAecm_ProcessBlock(webrtc::AecmCore*, short const*, short const*, short const*, short*)'; webrtc/modules/audio_processing/libwebrtc-audio-processing-1.so.3.p/aecm_aecm_core_c.cc.o:[...]/webrtc/modules/audio_processing/aecm/aecm_core_c.cc:377: first defined here
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
The MIPS-specific file is a replacement for the other, unlike the NEON
case. Don't add the default implementation unconditionally, add it only
for non-MIPS builds.
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Ongoing fixes and improvements, transient suppressor is gone. Also,
dropping isac because it doesn't seem to be useful, and is just build
system deadweight now.
Upstream references:
Version: 131.0.6778.200
WebRTC: 79aff54b0fa9238ce3518dd9eaf9610cd6f22e82
Chromium: 2a19506ad24af755f2a215a4c61f775393e0db42
Some API deprecation -- ExperimentalAgc and ExperimentalNs are gone.
We're continuing to carry iSAC even though it's gone upstream, but maybe
we'll want to drop that soon.
* add missing include as reported by gcc-13:
webrtc/modules/audio_processing/transient/file_utils.cc:11:
../webrtc-audio-processing-1.0/webrtc/modules/audio_processing/transient/file_utils.h:36:35: error: 'uint8_t' does not name a type
36 | int ConvertByteArrayToFloat(const uint8_t bytes[4], float* out);
| ^~~~~~~
webrtc/modules/audio_processing/transient/file_utils.h:17:1: note: 'uint8_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
16 | #include "rtc_base/system/file_wrapper.h"
+++ |+#include <cstdint>
17 |
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Since we cannot rely on the API to be stable upstream, let's start
making the pkg-config, library, and include dir have a version suffix.
This will allow different downstream projects depending on us to
independently switch versions without packagers having to jump through
hoops.
This new lib contains the bare minimum to implement an iSAC encoder and
decoder.
The webrtc files have been copied from the revision as the existing
imported files (c8b569e0a7ad0b369e15f0197b3a558699ec8efa).
In investigating x86/sse2 issues in recent webrtc-audio-processing-0.2
release, I found that it was possible for libwebrtc_audio_processing to
contain undefined symbols.
Attached is a patch that addresses this:
* adds -Wl,--no-undefined to libwebrtc_audio_processing_la_LDFLAGS
* adds explicit -lpthread linkage (else, there are undefined references
to pthread-related symbols)
Signed-off-by: Arun Raghavan <arun@arunraghavan.net>
On x86, SSE optimisations are always compiled in, and used based on
runtime checks.
On ARM, we try to autodetect NEON support (with an option of runtime
detection). This has not been build-tested on ARM yet.
This leaves MIPS to be done.
Corresponds to upstream commit 524e9b043e7e86fd72353b987c9d5f6a1ebf83e1
Update notes:
* Pull in third party license file
* Replace .gypi files with BUILD.gn to keep track of what changes
upstream
* Bunch of new filse pulled in as dependencies
* Won't build yet due to changes needed on top of these
Corresponds to upstream commit 524e9b043e7e86fd72353b987c9d5f6a1ebf83e1
Update notes:
* Moved src/ to webrtc/ to easily diff against the third_party/webrtc
in the chromium tree
* ARM/NEON/MIPS support is not yet hooked up
* Tests have not been copied