Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-07-06Avoid left shifts of negative values in debug macrosJean-Marc Valin
Reviewed by Mark Harris
2022-07-06Work around UBSan unaligned access errors.Timothy B. Terriberry
The underlying objects are all 8-bit integers. Verified that the generated assembly still just uses MOVD. Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2022-07-06Add asan/ubsan support in random testsJean-Marc Valin
2022-07-01Adds OPUS_SET_INBAND_FEC(2) optionJean-Marc Valin
Unlike OPUS_SET_INBAND_FEC(1), the encoder does not necessarily switch to SILK if we have music.
2022-06-30Estimate the inner product accuracy to fix check-asmJean-Marc Valin
Estimate the rounding error so that we can have a useful margin of error when checking the asm against the C code even when the float operations get reordered due to -ffast-math.
2022-06-30Adds fuzzing to CPU detectionJean-Marc Valin
Makes ti possible to randomize (with --enable-fuzzing) the CPU flags so we can better test all the intrinsics implementations.
2022-06-29Work around a valgrind false-positive in CPUID.Timothy B. Terriberry
Valgrind versions prior to 3.17.0 assume that an uninitialized value in ECX causes the whole output of CPUID to be uninitialized, even though ECX is only "read" by CPUID for certain values of EAX. Work around that by guaranteeing that ECX is initialized.
2022-06-29Check the return value of __get_cpuid().Timothy B. Terriberry
This function can fail if CPUID is not supported or the maximum supported value of EAX is less than the requested one. Check the return value and explicitly disable all SIMD if it does fail. This was happening before implicitly because of the initialization of info[] to zero, but being explicit about it makes it less likely someone will break this behavior because they did not realize what was going on.
2022-06-28Fixes valgrind failure caused by silk_find_pred_coefs_*()Jean-Marc Valin
The function copies NLSFs from the stack to the state which for order 10 means we were copying uninitialized values. That in turn breaks check-asm when comparing the state under valgrind. Reviewed by Timothy B. Terriberry.
2022-06-28Fixes --disable-rtcdJean-Marc Valin
Make sure we don't try to use the rtcd table when rtcd is disabled. That code still needs a lot more cleaning up.
2022-06-28Silence some warnings for fixed-point debug buildsJean-Marc Valin
Reviewed by Timothy B. Terriberry.
2022-06-28Fixes wrap-around in silk_inner_prod16_sse4_1()Jean-Marc Valin
Thanks Tim
2022-06-27Fix 8101b33 to decode ignored redundancyMark Harris
Even if the redundancy is ignored, the final range from the decoder is needed for testing. Reviewed by Timothy B. Terriberry.
2022-06-26Improve background noise estimation for CELT DTXJean-Marc Valin
We now update the background noise estimate even in frames classified as transient. It shouldn't be a problem because we're using min statistics. Also, it avoids problems when update frames get missclassified as transient. In addition, we now use the duration of losses rather than the number of lost packets to make decisions. That should make PLC/DTX behaviour more consistent across frame sizes.
2022-06-26Correct redundancy handling with lost/DTX framesMark Harris
In https://github.com/xiph/opus/issues/253, the encoder generates a Hybrid frame with redundancy, to switch to CELT-only mode, and then activates DTX immediately afterwards. The decoder ran Hybrid PLC, which isn't right. Use CELT PLC instead if there was already a transition to CELT via redundancy at the end of the previous frame. Also do not use a stale CELT decoder to decode a second redundancy frame when the first redundancy frame for a transition from SILK-only mode was lost. Instead of mixing in old audio from the last time that CELT was used, ignore the second redundancy frame in this case. Alternatively the CELT decoder could be reset before decoding, but it would not be ready until after the 2.5 ms of audio that is needed. Reviewed by Jean-Marc Valin.
2022-04-02print rate used for testvectorsJean-Marc Valin
2022-04-02Fix lrint/lrintf detectionJean-Marc Valin
Prevents using lrint/lrintf when compiling with -std=c90 even though the functions are in libm. This was causing tests to fail, likely due to incorrect prototypes.
2022-04-01Cleanup testing directories to save spaceJean-Marc Valin
2022-04-01build test scriptsJean-Marc Valin
2022-03-08Update and re-enable SILK SSE4.1 optimisationsFrancis Quiers
2022-02-24Prevent int32 overflow when applying HARM FIR filter in NSQ.c by using a ↵Tom Denton
saturating sum. This matches behavior in NSQ_del_dec.c. Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2022-01-15Initialize non-zero test arrays.Tom Denton
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2021-12-19Disable dangerous SSE 4.1 intrinsic optimizationsJean-Marc Valin
These could result in 16-byte-aligned loads on unaligned data, causing a segfault.
2021-12-15Fix buffer overflow in xcorr_kernel_sse4_1Felicia Lim
Before, an overflow can occur in the last loop if `len` is not a multiple of 4 as OP_CVTEPI16_EPI32_M64 tries to load 64 bits, but there are insufficient bits allocated in `x`.
2021-09-28Check channels/stream counts and mapping when creating the multistreamFelicia Lim
encoder
2021-07-08Remove an unused parameterFelicia Lim
2021-06-16meson: fix get-version script for git worktreesTim-Philipp Müller
For git worktree directories .git is not a directory but a file that points to the real .git dir. The `update_version` script used by other builds works correctly with git worktrees. Signed-off-by: Ralph Giles <giles@thaumas.net>
2021-06-10Revert relaxing comparison to 0 for fixed point onlyFelicia Lim
2021-06-08Relax comparison to 0 to avoid a floating point divide-by-zero error.Felicia Lim
2021-05-12cmake - add support to run ctest on android #2347Marcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2021-05-12Fix trailing whitespace.Ralph Giles
This was introduced in February, and fails the corresponding check in gitlab ci runs. Also indent the subsequent lines to match and correct typos. Signed-off-by: Mark Harris <mark.hsj@gmail.com>
2021-03-03celt_lpc: avoid overflows when computing lpcs in fixed pointFelicia Lim
The LPCs are computed in 32-bit, so increase the allowed range from +/-8 to +/-64 to avoid overflows caught during fuzzing. Before downshifting back down to the +/-8 range in the final 16-bit output, perform bandwidth extension to avoid any additional overflow issues.
2021-02-20Sending refresh DTX packets every 400 ms independently of the encoded frame ↵Jesús de Vicente Peña
size. Signed-off-by: Felicia Lim <flim@google.com>
2021-01-24Fix float-approx negative left shift UBMark Harris
Reported by toto.
2020-12-23ci: fix pipeline run for merge requestsTim-Philipp Müller
This way CI pipeline runs for branches and tags and makes it show up in merge requests where a branch is used as source branch. Makes all jobs show up in merge request CI indicator (not just the whitespace job) and only runs a single CI pipeline, without the additional detached pipeline. https://docs.gitlab.com/ce/ci/yaml/#workflowrules-templates Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-12-09docs: fix simple typo, neareast -> nearestTim Gates
There is a small typo in celt/fixed_generic.h. Should read `nearest` rather than `neareast`. Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-26Meson: Fix doc build when opus is a subprojectXavier Claessens
meson.source_root() and meson.build_root() have been deprecated in latest Meson release because they are a trap. They point to the root of parent project instead of root of current subproject. Meson 0.56.0 added meson.project_source/build_root() but it is just as easy to use meson.current_source/build_dir() in the root meson.build file and avoids bumping required meson version. Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - add option for fixed point debugMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - add option for check asmMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - add option for fuzzingMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - add option for hardeningMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - add option for assertionsMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21CMakeLists.txt: specify working directory in add_test() directivesDavide Beatrici
This is required for Windows because it doesn't have RPATH, thus it fails to find Opus if it's not in the same directory as the executables or in PATH. Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21CMakeLists.txt: specify path to target file in add_test() directivesDavide Beatrici
This is required in case the output path for tests is changed by a project adding Opus as submodule. Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-11-21cmake - change logging of api version to debugMarcus Asteborg
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-10-28Add support for Meson build systemTim-Philipp Müller
Tested on: - Linux/x86* with gcc - Android armv7 arm64 x86 x86_64 with clang - Windows x86 x86_64 with Visual Studio 2017 - Windows x86 x86_64 with MinGW - macOS x86_64 with clang - iOS arm64 x86_64 with clang Co-authored by: Nirbheek Chauhan <nirbheek@centricular.com> https://gitlab.xiph.org/xiph/opus/-/merge_requests/13
2020-08-22Fix MSVC warning about trunction from double to floatNirbheek Chauhan
Specify the precision as float to avoid truncating from double. Signed-off-by: Mark Harris <mark.hsj@gmail.com>
2020-08-22repacketizer_demo: check for read errors to fix compiler warningsNirbheek Chauhan
Actually check for read errors instead of just storing the return value in a variable that then never gets checked. Also fixes "conversion from 'size_t' to 'int', possible loss of data" compiler warnings on Windows with MSVC caused by storing the size_t returned by fread() into an int variable. Signed-off-by: Mark Harris <mark.hsj@gmail.com>
2020-08-22Replace WIN32 with _WIN32 everywhereNirbheek Chauhan
_WIN32 is defined on all Windows platforms by every compiler that targets Windows. We do not need WIN32 at all. Signed-off-by: Mark Harris <mark.hsj@gmail.com> Resolves https://github.com/xiph/opus/pull/104
2020-08-22celt: Fix broken SSE pre-processor check due to typoNirbheek Chauhan
This broke 5 years ago in 43120f00758219a784f952754f33b9788a8d731b Signed-off-by: Mark Harris <mark.hsj@gmail.com>