From ace38e14f6a2845409c8eeb0261e5270db1058e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Grisez?= Date: Tue, 1 Dec 2015 09:33:20 +0100 Subject: [PATCH 001/117] Update linphone submodule --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index f99fe0ced..590f6221a 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit f99fe0ced506dd6588dae8cdbf7b624e6f2f999c +Subproject commit 590f6221a2be3044d25154e9ce29fb1e61b5cadf From 3438603c469493b024d1843331073b5bb81a2986 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 1 Dec 2015 10:28:32 +0100 Subject: [PATCH 002/117] repair build --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 590f6221a..6a70c5c25 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 590f6221a2be3044d25154e9ce29fb1e61b5cadf +Subproject commit 6a70c5c257a02ce170cc0385c87d3e98eec94c81 From 38ac04bcfe21db169413fce3f3564382aaacab9c Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Fri, 4 Dec 2015 16:29:47 +0100 Subject: [PATCH 003/117] Fixed crash in realtime text message received callback (liblinphone updated) --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 6a70c5c25..7b04214da 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 6a70c5c257a02ce170cc0385c87d3e98eec94c81 +Subproject commit 7b04214dae674443ddf8d4c3a9791d538a3e4cc7 From 8a6a9dbbeac1a6f85c12c1d57cf40164f8751163 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Fri, 4 Dec 2015 16:44:00 +0100 Subject: [PATCH 004/117] Updated liblinphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 7b04214da..48510f300 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 7b04214dae674443ddf8d4c3a9791d538a3e4cc7 +Subproject commit 48510f3000961867d8de79899f0a5732f3fc0259 From 3a09160224ac1a69284b360c0f8bb7bdd4d681f9 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Fri, 4 Dec 2015 17:02:50 +0100 Subject: [PATCH 005/117] Updated liblinphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 48510f300..9d71678c2 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 48510f3000961867d8de79899f0a5732f3fc0259 +Subproject commit 9d71678c2863f723d4c2010ce292c41e09f42f3b From 2a1683230ca850546951f5a9afac7d195d4b630f Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Fri, 4 Dec 2015 17:15:38 +0100 Subject: [PATCH 006/117] [Outgrade submodule] Revert latests changes causing Android app to crash --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 9d71678c2..cfa911e27 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 9d71678c2863f723d4c2010ce292c41e09f42f3b +Subproject commit cfa911e27f62b456139509c5cac1541f895bf690 From 9a9ee1c9c3d41ebf5a0de9d443dae3e542c26632 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Mon, 7 Dec 2015 09:42:05 +0100 Subject: [PATCH 007/117] Updated liblinphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index cfa911e27..f95eb81ec 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit cfa911e27f62b456139509c5cac1541f895bf690 +Subproject commit f95eb81ec1a1e00ef0daaaa89466de02c96ce773 From 43d047ce01f85a040854d1bf2e15b54bd6202b03 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Mon, 7 Dec 2015 10:36:21 +0100 Subject: [PATCH 008/117] Updated liblinphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index f95eb81ec..917da92fb 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit f95eb81ec1a1e00ef0daaaa89466de02c96ce773 +Subproject commit 917da92fbf5f1c56cbe3cc13dc7106f3bead2a40 From 22f3986ccbba478d39e5db9297fc8a4f8e0a89d8 Mon Sep 17 00:00:00 2001 From: Sylvain Berfini Date: Tue, 8 Dec 2015 15:26:26 +0100 Subject: [PATCH 009/117] Updated liblinphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 917da92fb..6157e57bb 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 917da92fbf5f1c56cbe3cc13dc7106f3bead2a40 +Subproject commit 6157e57bbab468a6b8a297720b1cc3ba30eafd0c From 6576b4fd701bcc05f503d04e1411b2bd1b09a62c Mon Sep 17 00:00:00 2001 From: Sandrine Avakian Date: Mon, 14 Dec 2015 17:39:06 +0100 Subject: [PATCH 010/117] Update linphone-android with linphone submodules master branch version. --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 6157e57bb..689f1cf86 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 6157e57bbab468a6b8a297720b1cc3ba30eafd0c +Subproject commit 689f1cf86ff2a82c1b90fce30e9568d26a9051dd From 434840f8ec37eace3d179fe8208f517293d6fa00 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Thu, 17 Dec 2015 16:12:43 +0100 Subject: [PATCH 011/117] update linphone submodule to leave the choice of echo calibrator tones --- res/raw/linphonerc_factory | 6 +++++- submodules/linphone | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/res/raw/linphonerc_factory b/res/raw/linphonerc_factory index 763694075..cfa610120 100644 --- a/res/raw/linphonerc_factory +++ b/res/raw/linphonerc_factory @@ -30,7 +30,11 @@ remote_ring=/data/data/org.linphone/files/ringback.wav local_ring=/data/data/org.linphone/files/oldphone_mono.wav dtmf_player_amp=0.1 +#remove this property for any application that is not Linphone public version itself +ec_calibrator_cool_tones=1 + + [misc] max_calls=10 log_collection_upload_server_url=https://www.linphone.org:444/lft.php -user_certificates_path=/data/data/org.linphone/files \ No newline at end of file +user_certificates_path=/data/data/org.linphone/files diff --git a/submodules/linphone b/submodules/linphone index 689f1cf86..ea25eb10c 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 689f1cf86ff2a82c1b90fce30e9568d26a9051dd +Subproject commit ea25eb10c58ea45649d62b73ff418d213b7436ff From ae4927c45b1b631a533ff94ff36f13023806fdba Mon Sep 17 00:00:00 2001 From: Sandrine Avakian Date: Mon, 21 Dec 2015 09:48:19 +0100 Subject: [PATCH 012/117] Update linphone-android with linphone submodules master branch version with the feature RTCP feedback on AVP functional. --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index ea25eb10c..29d2355ba 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit ea25eb10c58ea45649d62b73ff418d213b7436ff +Subproject commit 29d2355ba7ee50a806999711098f348d61172ead From 83817e7641df2b88139f3101c7121ac3ad306a85 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 22 Dec 2015 08:43:46 +0100 Subject: [PATCH 013/117] update belle-sip and linphone --- submodules/belle-sip | 2 +- submodules/linphone | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/submodules/belle-sip b/submodules/belle-sip index 5ecb50825..4d5de406f 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit 5ecb508253f7f19d5c0b40d598fc9bec8ef6a447 +Subproject commit 4d5de406f9056025f96b4db7fbf867be9999d826 diff --git a/submodules/linphone b/submodules/linphone index 29d2355ba..c3049f287 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 29d2355ba7ee50a806999711098f348d61172ead +Subproject commit c3049f287f529d8373c90d68f11f70dddcc55232 From 9aafe16532b93867b98b146c98bfcf813064f9e3 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 22 Dec 2015 09:15:52 +0100 Subject: [PATCH 014/117] fix compilation problem with liblinphone_tester --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index c3049f287..e5b0030ea 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit c3049f287f529d8373c90d68f11f70dddcc55232 +Subproject commit e5b0030eaeb74d714894944234b0bd8d991fff31 From dd60aec55f12be4f4666937f34ba737ff8b29e50 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 22 Dec 2015 11:07:45 +0100 Subject: [PATCH 015/117] fix crash --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index e5b0030ea..467acd3d1 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit e5b0030eaeb74d714894944234b0bd8d991fff31 +Subproject commit 467acd3d1b08610843fc172658a1c285c1b58030 From 421f4f24baaab9c365e816b372d5c519689ddf8f Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Tue, 22 Dec 2015 16:55:59 +0100 Subject: [PATCH 016/117] Add mediacodec support --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 467acd3d1..c1102388a 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 467acd3d1b08610843fc172658a1c285c1b58030 +Subproject commit c1102388aef2a783cde4056c793bcdc4288e0ed8 From efce905206a8f3aa7ce6d3510e936c263cb72861 Mon Sep 17 00:00:00 2001 From: Sandrine Avakian Date: Wed, 23 Dec 2015 11:29:08 +0100 Subject: [PATCH 017/117] Propagating modifications from linphone on RTCP feddback to linphone-android. --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index c1102388a..af1070f04 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit c1102388aef2a783cde4056c793bcdc4288e0ed8 +Subproject commit af1070f04ce4c51b892315d52ebe0eacae2d4d47 From 4c1d5febb07c0b0c0cf151b599db3fe4300398c8 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Sun, 27 Dec 2015 12:36:27 +0100 Subject: [PATCH 018/117] update linphone submodule --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index af1070f04..f922907fd 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit af1070f04ce4c51b892315d52ebe0eacae2d4d47 +Subproject commit f922907fd8af8ac8926e72d07104d359408c81dc From ca0341ae6c3ab5db1692893128e453b25de259f7 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Mon, 4 Jan 2016 12:21:32 +0100 Subject: [PATCH 019/117] update external submodules: - opus to 1.1.1 - openh264 to 1.5 - libvpx to 1.5 --- Makefile | 4 ++-- patches/libvpx_configure_android_x86.patch | 7 +++---- submodules/externals/build/opus/Android.mk | 16 ++++++++++++++++ submodules/externals/build/opus/config.h | 4 ++++ submodules/externals/libvpx | 2 +- submodules/externals/openh264 | 2 +- submodules/externals/opus | 2 +- 7 files changed, 28 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index 275325f34..d87636744 100644 --- a/Makefile +++ b/Makefile @@ -303,13 +303,13 @@ openh264-install-headers: mkdir -p $(OPENH264_SRC_DIR)/include/wels rsync -rvLpgoc --exclude ".git" $(OPENH264_SRC_DIR)/codec/api/svc/* $(OPENH264_SRC_DIR)/include/wels/. -copy-openh264-x86: openh264-patch openh264-install-headers +copy-openh264-x86: openh264-install-headers mkdir -p $(OPENH264_BUILD_DIR) mkdir -p $(OPENH264_BUILD_DIR_X86) cd $(OPENH264_BUILD_DIR_X86) \ && rsync -rvLpgoc --exclude ".git" $(OPENH264_SRC_DIR)/* . -copy-openh264-arm: openh264-patch openh264-install-headers +copy-openh264-arm: openh264-install-headers mkdir -p $(OPENH264_BUILD_DIR) mkdir -p $(OPENH264_BUILD_DIR_ARM) cd $(OPENH264_BUILD_DIR_ARM) \ diff --git a/patches/libvpx_configure_android_x86.patch b/patches/libvpx_configure_android_x86.patch index 6c7f40e97..fa1004599 100644 --- a/patches/libvpx_configure_android_x86.patch +++ b/patches/libvpx_configure_android_x86.patch @@ -1,10 +1,10 @@ diff --git a/build/make/configure.sh b/build/make/configure.sh -index 25c9f80..336b006 100644 +index c592b63..e4998d7 100644 --- a/build/make/configure.sh +++ b/build/make/configure.sh -@@ -1082,6 +1082,33 @@ EOF - os2) +@@ -1132,6 +1132,32 @@ EOF AS=${AS:-nasm} + add_ldflags -Zhigh-mem ;; + android*) + SDK_PATH=${sdk_path} @@ -32,7 +32,6 @@ index 25c9f80..336b006 100644 + + soft_enable realtime_only + ;; -+ esac AS="${alt_as:-${AS:-auto}}" diff --git a/submodules/externals/build/opus/Android.mk b/submodules/externals/build/opus/Android.mk index 7e4718660..b1033fa8e 100644 --- a/submodules/externals/build/opus/Android.mk +++ b/submodules/externals/build/opus/Android.mk @@ -92,6 +92,22 @@ LOCAL_C_INCLUDES += \ LOCAL_CFLAGS += -include ../build/opus/config.h +ifeq ($(TARGET_ARCH),arm) + LOCAL_SRC_FILES += celt/arm/arm_celt_map.c \ + celt/arm/armcpu.c + + +# celt/arm/celt_ne10_fft.c +# celt/arm/celt_ne10_mdct.c + + ifeq ($(TARGET_ARCH_ABI),armeabi-v7a) + LOCAL_CFLAGS += -DOPUS_ARM_MAY_HAVE_NEON=1 -DOPUS_ARM_MAY_HAVE_NEON_INTR=1 + # These two files were generated by hand using asm2gnu.pl script of opus. + LOCAL_SRC_FILES += ../build/opus/celt_pitch_xcorr_arm.S.neon \ + celt/arm/celt_neon_intr.c.neon + endif +endif + LOCAL_ARM_MODE := arm diff --git a/submodules/externals/build/opus/config.h b/submodules/externals/build/opus/config.h index 284c31e1e..3044bdee0 100644 --- a/submodules/externals/build/opus/config.h +++ b/submodules/externals/build/opus/config.h @@ -138,3 +138,7 @@ # define _Restrict # define __restrict__ #endif + + + + diff --git a/submodules/externals/libvpx b/submodules/externals/libvpx index c74bf6d88..cbecf57f3 160000 --- a/submodules/externals/libvpx +++ b/submodules/externals/libvpx @@ -1 +1 @@ -Subproject commit c74bf6d889992c3cabe017ec353ca85c323107cd +Subproject commit cbecf57f3e0d85a7b7f97f3ab7c507f6fe640a93 diff --git a/submodules/externals/openh264 b/submodules/externals/openh264 index 3a75956fb..2610ab183 160000 --- a/submodules/externals/openh264 +++ b/submodules/externals/openh264 @@ -1 +1 @@ -Subproject commit 3a75956fb2584cca84a95ba1fcbc72fa2c91f98d +Subproject commit 2610ab183249aee91862d2ad065f61db89107b34 diff --git a/submodules/externals/opus b/submodules/externals/opus index 4e8acd5ca..1f22ae379 160000 --- a/submodules/externals/opus +++ b/submodules/externals/opus @@ -1 +1 @@ -Subproject commit 4e8acd5ca305f385715a2c36642fdbc91503134f +Subproject commit 1f22ae379bbcdfa376775db2b9407529fb1fa781 From 65185ac146b25af56b8a5201238ba3061dbb6716 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Mon, 4 Jan 2016 15:40:34 +0100 Subject: [PATCH 020/117] add --enable-pic for libvpx configure option (removes non-relocatable code for x86) --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index d87636744..e7f81cb53 100644 --- a/Makefile +++ b/Makefile @@ -339,7 +339,7 @@ endif endif LIBVPX_SRC_DIR=$(TOPDIR)/submodules/externals/libvpx LIBVPX_BUILD_DIR=$(TOPDIR)/submodules/externals/build/libvpx -LIBVPX_CONFIGURE_OPTIONS=--disable-vp9 --disable-examples --disable-unit-tests --disable-postproc --enable-error-concealment --enable-debug +LIBVPX_CONFIGURE_OPTIONS=--disable-vp9 --disable-examples --disable-unit-tests --disable-postproc --enable-error-concealment --enable-pic $(LIBVPX_SRC_DIR)/configure_android_x86_patch_applied.txt: cd $(LIBVPX_SRC_DIR) && patch -p1 < $(TOPDIR)/patches/libvpx_configure_android_x86.patch From 34077f7bebf886af81b12d027fea86ef5f85547d Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 5 Jan 2016 09:45:42 +0100 Subject: [PATCH 021/117] add missing files --- submodules/externals/build/opus/armopts-gnu.S | 38 ++ .../build/opus/celt_pitch_xcorr_arm.S | 551 ++++++++++++++++++ 2 files changed, 589 insertions(+) create mode 100644 submodules/externals/build/opus/armopts-gnu.S create mode 100644 submodules/externals/build/opus/celt_pitch_xcorr_arm.S diff --git a/submodules/externals/build/opus/armopts-gnu.S b/submodules/externals/build/opus/armopts-gnu.S new file mode 100644 index 000000000..a42ce0831 --- /dev/null +++ b/submodules/externals/build/opus/armopts-gnu.S @@ -0,0 +1,38 @@ + .syntax unified +/* Copyright (C) 2013 Mozilla Corporation */ +/* + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + - Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + - Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER + OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES@ LOSS OF USE, @ DATA, OR + PROFITS@ OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN .if ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +*/ + +@ Set the following to 1 if we have EDSP instructions +@ (LDRD/STRD, etc., ARMv5E and later). + .set OPUS_ARM_MAY_HAVE_EDSP, 0 + +@ Set the following to 1 if we have ARMv6 media instructions. + .set OPUS_ARM_MAY_HAVE_MEDIA, 0 + +@ Set the following to 1 if we have NEON (some ARMv7) + .set OPUS_ARM_MAY_HAVE_NEON, 1 + +@ END: diff --git a/submodules/externals/build/opus/celt_pitch_xcorr_arm.S b/submodules/externals/build/opus/celt_pitch_xcorr_arm.S new file mode 100644 index 000000000..54b4cbbe3 --- /dev/null +++ b/submodules/externals/build/opus/celt_pitch_xcorr_arm.S @@ -0,0 +1,551 @@ + .syntax unified +@ Copyright (c) 2007-2008 CSIRO +@ Copyright (c) 2007-2009 Xiph.Org Foundation +@ Copyright (c) 2013 Parrot +@ Written by Aurélien Zanelli +@ +@ Redistribution and use in source and binary forms, with or without +@ modification, are permitted provided that the following conditions +@ are met: +@ +@ - Redistributions of source code must retain the above copyright +@ notice, this list of conditions and the following disclaimer. +@ +@ - Redistributions in binary form must reproduce the above copyright +@ notice, this list of conditions and the following disclaimer in the +@ documentation and/or other materials provided with the distribution. +@ +@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +@ ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +@ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +@ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER +@ OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +@ EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +@ PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +@ PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +@ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +@ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + .text; .p2align 2; .arch armv7-a + .fpu neon + .object_arch armv4t + + .include "../build/opus/armopts-gnu.S" + + .if OPUS_ARM_MAY_HAVE_EDSP + .global celt_pitch_xcorr_edsp + .endif + + .if OPUS_ARM_MAY_HAVE_NEON + .global celt_pitch_xcorr_neon + .endif + + .if OPUS_ARM_MAY_HAVE_NEON + +@ Compute sum[k]=sum(x[j]*y[j+k],j=0...len-1), k=0...3 +; xcorr_kernel_neon: @ PROC +xcorr_kernel_neon_start: + @ input: + @ r3 = int len + @ r4 = opus_val16 *x + @ r5 = opus_val16 *y + @ q0 = opus_val32 sum[4] + @ output: + @ q0 = opus_val32 sum[4] + @ preserved: r0-r3, r6-r11, d2, q4-q7, q9-q15 + @ internal usage: + @ r12 = int j + @ d3 = y_3|y_2|y_1|y_0 + @ q2 = y_B|y_A|y_9|y_8|y_7|y_6|y_5|y_4 + @ q3 = x_7|x_6|x_5|x_4|x_3|x_2|x_1|x_0 + @ q8 = scratch + @ + @ Load y[0...3] + @ This requires len>0 to always be valid (which we assert in the C code). + VLD1.16 {d5}, [r5]! + SUBS r12, r3, #8 + BLE xcorr_kernel_neon_process4 +@ Process 8 samples at a time. +@ This loop loads one y value more than we actually need. Therefore we have to +@ stop as soon as there are 8 or fewer samples left (instead of 7), to avoid +@ reading past the end of the array. +xcorr_kernel_neon_process8: + @ This loop has 19 total instructions (10 cycles to issue, minimum), with + @ - 2 cycles of ARM insrtuctions, + @ - 10 cycles of load/store/byte permute instructions, and + @ - 9 cycles of data processing instructions. + @ On a Cortex A8, we dual-issue the maximum amount (9 cycles) between the + @ latter two categories, meaning the whole loop should run in 10 cycles per + @ iteration, barring cache misses. + @ + @ Load x[0...7] + VLD1.16 {d6, d7}, [r4]! + @ Unlike VMOV, VAND is a data processsing instruction (and doesn't get + @ assembled to VMOV, like VORR would), so it dual-issues with the prior VLD1. + VAND d3, d5, d5 + SUBS r12, r12, #8 + @ Load y[4...11] + VLD1.16 {d4, d5}, [r5]! + VMLAL.S16 q0, d3, d6[0] + VEXT.16 d16, d3, d4, #1 + VMLAL.S16 q0, d4, d7[0] + VEXT.16 d17, d4, d5, #1 + VMLAL.S16 q0, d16, d6[1] + VEXT.16 d16, d3, d4, #2 + VMLAL.S16 q0, d17, d7[1] + VEXT.16 d17, d4, d5, #2 + VMLAL.S16 q0, d16, d6[2] + VEXT.16 d16, d3, d4, #3 + VMLAL.S16 q0, d17, d7[2] + VEXT.16 d17, d4, d5, #3 + VMLAL.S16 q0, d16, d6[3] + VMLAL.S16 q0, d17, d7[3] + BGT xcorr_kernel_neon_process8 +@ Process 4 samples here if we have > 4 left (still reading one extra y value). +xcorr_kernel_neon_process4: + ADDS r12, r12, #4 + BLE xcorr_kernel_neon_process2 + @ Load x[0...3] + VLD1.16 d6, [r4]! + @ Use VAND since it's a data processing instruction again. + VAND d4, d5, d5 + SUB r12, r12, #4 + @ Load y[4...7] + VLD1.16 d5, [r5]! + VMLAL.S16 q0, d4, d6[0] + VEXT.16 d16, d4, d5, #1 + VMLAL.S16 q0, d16, d6[1] + VEXT.16 d16, d4, d5, #2 + VMLAL.S16 q0, d16, d6[2] + VEXT.16 d16, d4, d5, #3 + VMLAL.S16 q0, d16, d6[3] +@ Process 2 samples here if we have > 2 left (still reading one extra y value). +xcorr_kernel_neon_process2: + ADDS r12, r12, #2 + BLE xcorr_kernel_neon_process1 + @ Load x[0...1] + VLD2.16 {d6[],d7[]}, [r4]! + @ Use VAND since it's a data processing instruction again. + VAND d4, d5, d5 + SUB r12, r12, #2 + @ Load y[4...5] + VLD1.32 {d5[]}, [r5]! + VMLAL.S16 q0, d4, d6 + VEXT.16 d16, d4, d5, #1 + @ Replace bottom copy of {y5,y4} in d5 with {y3,y2} from d4, using VSRI + @ instead of VEXT, since it's a data-processing instruction. + VSRI.64 d5, d4, #32 + VMLAL.S16 q0, d16, d7 +@ Process 1 sample using the extra y value we loaded above. +xcorr_kernel_neon_process1: + @ Load next *x + VLD1.16 {d6[]}, [r4]! + ADDS r12, r12, #1 + @ y[0...3] are left in d5 from prior iteration(s) (if any) + VMLAL.S16 q0, d5, d6 + MOVLE pc, lr +@ Now process 1 last sample, not reading ahead. + @ Load last *y + VLD1.16 {d4[]}, [r5]! + VSRI.64 d4, d5, #16 + @ Load last *x + VLD1.16 {d6[]}, [r4]! + VMLAL.S16 q0, d4, d6 + MOV pc, lr + .size xcorr_kernel_neon, .-xcorr_kernel_neon @ ENDP + +@ opus_val32 celt_pitch_xcorr_neon(opus_val16 *_x, opus_val16 *_y, +@ opus_val32 *xcorr, int len, int max_pitch) +; celt_pitch_xcorr_neon: @ PROC + @ input: + @ r0 = opus_val16 *_x + @ r1 = opus_val16 *_y + @ r2 = opus_val32 *xcorr + @ r3 = int len + @ output: + @ r0 = int maxcorr + @ internal usage: + @ r4 = opus_val16 *x (for xcorr_kernel_neon()) + @ r5 = opus_val16 *y (for xcorr_kernel_neon()) + @ r6 = int max_pitch + @ r12 = int j + @ q15 = int maxcorr[4] (q15 is not used by xcorr_kernel_neon()) + STMFD sp!, {r4-r6, lr} + LDR r6, [sp, #16] + VMOV.S32 q15, #1 + @ if (max_pitch < 4) goto celt_pitch_xcorr_neon_process4_done + SUBS r6, r6, #4 + BLT celt_pitch_xcorr_neon_process4_done +celt_pitch_xcorr_neon_process4: + @ xcorr_kernel_neon parameters: + @ r3 = len, r4 = _x, r5 = _y, q0 = {0, 0, 0, 0} + MOV r4, r0 + MOV r5, r1 + VEOR q0, q0, q0 + @ xcorr_kernel_neon only modifies r4, r5, r12, and q0...q3. + @ So we don't save/restore any other registers. + BL xcorr_kernel_neon_start + SUBS r6, r6, #4 + VST1.32 {q0}, [r2]! + @ _y += 4 + ADD r1, r1, #8 + VMAX.S32 q15, q15, q0 + @ if (max_pitch < 4) goto celt_pitch_xcorr_neon_process4_done + BGE celt_pitch_xcorr_neon_process4 +@ We have less than 4 sums left to compute. +celt_pitch_xcorr_neon_process4_done: + ADDS r6, r6, #4 + @ Reduce maxcorr to a single value + VMAX.S32 d30, d30, d31 + VPMAX.S32 d30, d30, d30 + @ if (max_pitch <= 0) goto celt_pitch_xcorr_neon_done + BLE celt_pitch_xcorr_neon_done +@ Now compute each remaining sum one at a time. +celt_pitch_xcorr_neon_process_remaining: + MOV r4, r0 + MOV r5, r1 + VMOV.I32 q0, #0 + SUBS r12, r3, #8 + BLT celt_pitch_xcorr_neon_process_remaining4 +@ Sum terms 8 at a time. +celt_pitch_xcorr_neon_process_remaining_loop8: + @ Load x[0...7] + VLD1.16 {q1}, [r4]! + @ Load y[0...7] + VLD1.16 {q2}, [r5]! + SUBS r12, r12, #8 + VMLAL.S16 q0, d4, d2 + VMLAL.S16 q0, d5, d3 + BGE celt_pitch_xcorr_neon_process_remaining_loop8 +@ Sum terms 4 at a time. +celt_pitch_xcorr_neon_process_remaining4: + ADDS r12, r12, #4 + BLT celt_pitch_xcorr_neon_process_remaining4_done + @ Load x[0...3] + VLD1.16 {d2}, [r4]! + @ Load y[0...3] + VLD1.16 {d3}, [r5]! + SUB r12, r12, #4 + VMLAL.S16 q0, d3, d2 +celt_pitch_xcorr_neon_process_remaining4_done: + @ Reduce the sum to a single value. + VADD.S32 d0, d0, d1 + VPADDL.S32 d0, d0 + ADDS r12, r12, #4 + BLE celt_pitch_xcorr_neon_process_remaining_loop_done +@ Sum terms 1 at a time. +celt_pitch_xcorr_neon_process_remaining_loop1: + VLD1.16 {d2[]}, [r4]! + VLD1.16 {d3[]}, [r5]! + SUBS r12, r12, #1 + VMLAL.S16 q0, d2, d3 + BGT celt_pitch_xcorr_neon_process_remaining_loop1 +celt_pitch_xcorr_neon_process_remaining_loop_done: + VST1.32 {d0[0]}, [r2]! + VMAX.S32 d30, d30, d0 + SUBS r6, r6, #1 + @ _y++ + ADD r1, r1, #2 + @ if (--max_pitch > 0) goto celt_pitch_xcorr_neon_process_remaining + BGT celt_pitch_xcorr_neon_process_remaining +celt_pitch_xcorr_neon_done: + VMOV.32 r0, d30[0] + LDMFD sp!, {r4-r6, pc} + .size celt_pitch_xcorr_neon, .-celt_pitch_xcorr_neon @ ENDP + + .endif + + .if OPUS_ARM_MAY_HAVE_EDSP + +@ This will get used on ARMv7 devices without NEON, so it has been optimized +@ to take advantage of dual-issuing where possible. +; xcorr_kernel_edsp: @ PROC +xcorr_kernel_edsp_start: + @ input: + @ r3 = int len + @ r4 = opus_val16 *_x (must be 32-bit aligned) + @ r5 = opus_val16 *_y (must be 32-bit aligned) + @ r6...r9 = opus_val32 sum[4] + @ output: + @ r6...r9 = opus_val32 sum[4] + @ preserved: r0-r5 + @ internal usage + @ r2 = int j + @ r12,r14 = opus_val16 x[4] + @ r10,r11 = opus_val16 y[4] + STMFD sp!, {r2,r4,r5,lr} + LDR r10, [r5], #4 @ Load y[0...1] + SUBS r2, r3, #4 @ j = len-4 + LDR r11, [r5], #4 @ Load y[2...3] + BLE xcorr_kernel_edsp_process4_done + LDR r12, [r4], #4 @ Load x[0...1] + @ Stall +xcorr_kernel_edsp_process4: + @ The multiplies must issue from pipeline 0, and can't dual-issue with each + @ other. Every other instruction here dual-issues with a multiply, and is + @ thus "free". There should be no stalls in the body of the loop. + SMLABB r6, r12, r10, r6 @ sum[0] = MAC16_16(sum[0],x_0,y_0) + LDR r14, [r4], #4 @ Load x[2...3] + SMLABT r7, r12, r10, r7 @ sum[1] = MAC16_16(sum[1],x_0,y_1) + SUBS r2, r2, #4 @ j-=4 + SMLABB r8, r12, r11, r8 @ sum[2] = MAC16_16(sum[2],x_0,y_2) + SMLABT r9, r12, r11, r9 @ sum[3] = MAC16_16(sum[3],x_0,y_3) + SMLATT r6, r12, r10, r6 @ sum[0] = MAC16_16(sum[0],x_1,y_1) + LDR r10, [r5], #4 @ Load y[4...5] + SMLATB r7, r12, r11, r7 @ sum[1] = MAC16_16(sum[1],x_1,y_2) + SMLATT r8, r12, r11, r8 @ sum[2] = MAC16_16(sum[2],x_1,y_3) + SMLATB r9, r12, r10, r9 @ sum[3] = MAC16_16(sum[3],x_1,y_4) + LDRGT r12, [r4], #4 @ Load x[0...1] + SMLABB r6, r14, r11, r6 @ sum[0] = MAC16_16(sum[0],x_2,y_2) + SMLABT r7, r14, r11, r7 @ sum[1] = MAC16_16(sum[1],x_2,y_3) + SMLABB r8, r14, r10, r8 @ sum[2] = MAC16_16(sum[2],x_2,y_4) + SMLABT r9, r14, r10, r9 @ sum[3] = MAC16_16(sum[3],x_2,y_5) + SMLATT r6, r14, r11, r6 @ sum[0] = MAC16_16(sum[0],x_3,y_3) + LDR r11, [r5], #4 @ Load y[6...7] + SMLATB r7, r14, r10, r7 @ sum[1] = MAC16_16(sum[1],x_3,y_4) + SMLATT r8, r14, r10, r8 @ sum[2] = MAC16_16(sum[2],x_3,y_5) + SMLATB r9, r14, r11, r9 @ sum[3] = MAC16_16(sum[3],x_3,y_6) + BGT xcorr_kernel_edsp_process4 +xcorr_kernel_edsp_process4_done: + ADDS r2, r2, #4 + BLE xcorr_kernel_edsp_done + LDRH r12, [r4], #2 @ r12 = *x++ + SUBS r2, r2, #1 @ j-- + @ Stall + SMLABB r6, r12, r10, r6 @ sum[0] = MAC16_16(sum[0],x,y_0) + LDRHGT r14, [r4], #2 @ r14 = *x++ + SMLABT r7, r12, r10, r7 @ sum[1] = MAC16_16(sum[1],x,y_1) + SMLABB r8, r12, r11, r8 @ sum[2] = MAC16_16(sum[2],x,y_2) + SMLABT r9, r12, r11, r9 @ sum[3] = MAC16_16(sum[3],x,y_3) + BLE xcorr_kernel_edsp_done + SMLABT r6, r14, r10, r6 @ sum[0] = MAC16_16(sum[0],x,y_1) + SUBS r2, r2, #1 @ j-- + SMLABB r7, r14, r11, r7 @ sum[1] = MAC16_16(sum[1],x,y_2) + LDRH r10, [r5], #2 @ r10 = y_4 = *y++ + SMLABT r8, r14, r11, r8 @ sum[2] = MAC16_16(sum[2],x,y_3) + LDRHGT r12, [r4], #2 @ r12 = *x++ + SMLABB r9, r14, r10, r9 @ sum[3] = MAC16_16(sum[3],x,y_4) + BLE xcorr_kernel_edsp_done + SMLABB r6, r12, r11, r6 @ sum[0] = MAC16_16(sum[0],tmp,y_2) + CMP r2, #1 @ j-- + SMLABT r7, r12, r11, r7 @ sum[1] = MAC16_16(sum[1],tmp,y_3) + LDRH r2, [r5], #2 @ r2 = y_5 = *y++ + SMLABB r8, r12, r10, r8 @ sum[2] = MAC16_16(sum[2],tmp,y_4) + LDRHGT r14, [r4] @ r14 = *x + SMLABB r9, r12, r2, r9 @ sum[3] = MAC16_16(sum[3],tmp,y_5) + BLE xcorr_kernel_edsp_done + SMLABT r6, r14, r11, r6 @ sum[0] = MAC16_16(sum[0],tmp,y_3) + LDRH r11, [r5] @ r11 = y_6 = *y + SMLABB r7, r14, r10, r7 @ sum[1] = MAC16_16(sum[1],tmp,y_4) + SMLABB r8, r14, r2, r8 @ sum[2] = MAC16_16(sum[2],tmp,y_5) + SMLABB r9, r14, r11, r9 @ sum[3] = MAC16_16(sum[3],tmp,y_6) +xcorr_kernel_edsp_done: + LDMFD sp!, {r2,r4,r5,pc} + .size xcorr_kernel_edsp, .-xcorr_kernel_edsp @ ENDP + +; celt_pitch_xcorr_edsp: @ PROC + @ input: + @ r0 = opus_val16 *_x (must be 32-bit aligned) + @ r1 = opus_val16 *_y (only needs to be 16-bit aligned) + @ r2 = opus_val32 *xcorr + @ r3 = int len + @ output: + @ r0 = maxcorr + @ internal usage + @ r4 = opus_val16 *x + @ r5 = opus_val16 *y + @ r6 = opus_val32 sum0 + @ r7 = opus_val32 sum1 + @ r8 = opus_val32 sum2 + @ r9 = opus_val32 sum3 + @ r1 = int max_pitch + @ r12 = int j + STMFD sp!, {r4-r11, lr} + MOV r5, r1 + LDR r1, [sp, #36] + MOV r4, r0 + TST r5, #3 + @ maxcorr = 1 + MOV r0, #1 + BEQ celt_pitch_xcorr_edsp_process1u_done +@ Compute one sum at the start to make y 32-bit aligned. + SUBS r12, r3, #4 + @ r14 = sum = 0 + MOV r14, #0 + LDRH r8, [r5], #2 + BLE celt_pitch_xcorr_edsp_process1u_loop4_done + LDR r6, [r4], #4 + MOV r8, r8, LSL #16 +celt_pitch_xcorr_edsp_process1u_loop4: + LDR r9, [r5], #4 + SMLABT r14, r6, r8, r14 @ sum = MAC16_16(sum, x_0, y_0) + LDR r7, [r4], #4 + SMLATB r14, r6, r9, r14 @ sum = MAC16_16(sum, x_1, y_1) + LDR r8, [r5], #4 + SMLABT r14, r7, r9, r14 @ sum = MAC16_16(sum, x_2, y_2) + SUBS r12, r12, #4 @ j-=4 + SMLATB r14, r7, r8, r14 @ sum = MAC16_16(sum, x_3, y_3) + LDRGT r6, [r4], #4 + BGT celt_pitch_xcorr_edsp_process1u_loop4 + MOV r8, r8, LSR #16 +celt_pitch_xcorr_edsp_process1u_loop4_done: + ADDS r12, r12, #4 +celt_pitch_xcorr_edsp_process1u_loop1: + LDRHGE r6, [r4], #2 + @ Stall + SMLABBGE r14, r6, r8, r14 @ sum = MAC16_16(sum, *x, *y) + SUBSGE r12, r12, #1 + LDRHGT r8, [r5], #2 + BGT celt_pitch_xcorr_edsp_process1u_loop1 + @ Restore _x + SUB r4, r4, r3, LSL #1 + @ Restore and advance _y + SUB r5, r5, r3, LSL #1 + @ maxcorr = max(maxcorr, sum) + CMP r0, r14 + ADD r5, r5, #2 + MOVLT r0, r14 + SUBS r1, r1, #1 + @ xcorr[i] = sum + STR r14, [r2], #4 + BLE celt_pitch_xcorr_edsp_done +celt_pitch_xcorr_edsp_process1u_done: + @ if (max_pitch < 4) goto celt_pitch_xcorr_edsp_process2 + SUBS r1, r1, #4 + BLT celt_pitch_xcorr_edsp_process2 +celt_pitch_xcorr_edsp_process4: + @ xcorr_kernel_edsp parameters: + @ r3 = len, r4 = _x, r5 = _y, r6...r9 = sum[4] = {0, 0, 0, 0} + MOV r6, #0 + MOV r7, #0 + MOV r8, #0 + MOV r9, #0 + BL xcorr_kernel_edsp_start @ xcorr_kernel_edsp(_x, _y+i, xcorr+i, len) + @ maxcorr = max(maxcorr, sum0, sum1, sum2, sum3) + CMP r0, r6 + @ _y+=4 + ADD r5, r5, #8 + MOVLT r0, r6 + CMP r0, r7 + MOVLT r0, r7 + CMP r0, r8 + MOVLT r0, r8 + CMP r0, r9 + MOVLT r0, r9 + STMIA r2!, {r6-r9} + SUBS r1, r1, #4 + BGE celt_pitch_xcorr_edsp_process4 +celt_pitch_xcorr_edsp_process2: + ADDS r1, r1, #2 + BLT celt_pitch_xcorr_edsp_process1a + SUBS r12, r3, #4 + @ {r10, r11} = {sum0, sum1} = {0, 0} + MOV r10, #0 + MOV r11, #0 + LDR r8, [r5], #4 + BLE celt_pitch_xcorr_edsp_process2_loop_done + LDR r6, [r4], #4 + LDR r9, [r5], #4 +celt_pitch_xcorr_edsp_process2_loop4: + SMLABB r10, r6, r8, r10 @ sum0 = MAC16_16(sum0, x_0, y_0) + LDR r7, [r4], #4 + SMLABT r11, r6, r8, r11 @ sum1 = MAC16_16(sum1, x_0, y_1) + SUBS r12, r12, #4 @ j-=4 + SMLATT r10, r6, r8, r10 @ sum0 = MAC16_16(sum0, x_1, y_1) + LDR r8, [r5], #4 + SMLATB r11, r6, r9, r11 @ sum1 = MAC16_16(sum1, x_1, y_2) + LDRGT r6, [r4], #4 + SMLABB r10, r7, r9, r10 @ sum0 = MAC16_16(sum0, x_2, y_2) + SMLABT r11, r7, r9, r11 @ sum1 = MAC16_16(sum1, x_2, y_3) + SMLATT r10, r7, r9, r10 @ sum0 = MAC16_16(sum0, x_3, y_3) + LDRGT r9, [r5], #4 + SMLATB r11, r7, r8, r11 @ sum1 = MAC16_16(sum1, x_3, y_4) + BGT celt_pitch_xcorr_edsp_process2_loop4 +celt_pitch_xcorr_edsp_process2_loop_done: + ADDS r12, r12, #2 + BLE celt_pitch_xcorr_edsp_process2_1 + LDR r6, [r4], #4 + @ Stall + SMLABB r10, r6, r8, r10 @ sum0 = MAC16_16(sum0, x_0, y_0) + LDR r9, [r5], #4 + SMLABT r11, r6, r8, r11 @ sum1 = MAC16_16(sum1, x_0, y_1) + SUB r12, r12, #2 + SMLATT r10, r6, r8, r10 @ sum0 = MAC16_16(sum0, x_1, y_1) + MOV r8, r9 + SMLATB r11, r6, r9, r11 @ sum1 = MAC16_16(sum1, x_1, y_2) +celt_pitch_xcorr_edsp_process2_1: + LDRH r6, [r4], #2 + ADDS r12, r12, #1 + @ Stall + SMLABB r10, r6, r8, r10 @ sum0 = MAC16_16(sum0, x_0, y_0) + LDRHGT r7, [r4], #2 + SMLABT r11, r6, r8, r11 @ sum1 = MAC16_16(sum1, x_0, y_1) + BLE celt_pitch_xcorr_edsp_process2_done + LDRH r9, [r5], #2 + SMLABT r10, r7, r8, r10 @ sum0 = MAC16_16(sum0, x_0, y_1) + SMLABB r11, r7, r9, r11 @ sum1 = MAC16_16(sum1, x_0, y_2) +celt_pitch_xcorr_edsp_process2_done: + @ Restore _x + SUB r4, r4, r3, LSL #1 + @ Restore and advance _y + SUB r5, r5, r3, LSL #1 + @ maxcorr = max(maxcorr, sum0) + CMP r0, r10 + ADD r5, r5, #2 + MOVLT r0, r10 + SUB r1, r1, #2 + @ maxcorr = max(maxcorr, sum1) + CMP r0, r11 + @ xcorr[i] = sum + STR r10, [r2], #4 + MOVLT r0, r11 + STR r11, [r2], #4 +celt_pitch_xcorr_edsp_process1a: + ADDS r1, r1, #1 + BLT celt_pitch_xcorr_edsp_done + SUBS r12, r3, #4 + @ r14 = sum = 0 + MOV r14, #0 + BLT celt_pitch_xcorr_edsp_process1a_loop_done + LDR r6, [r4], #4 + LDR r8, [r5], #4 + LDR r7, [r4], #4 + LDR r9, [r5], #4 +celt_pitch_xcorr_edsp_process1a_loop4: + SMLABB r14, r6, r8, r14 @ sum = MAC16_16(sum, x_0, y_0) + SUBS r12, r12, #4 @ j-=4 + SMLATT r14, r6, r8, r14 @ sum = MAC16_16(sum, x_1, y_1) + LDRGE r6, [r4], #4 + SMLABB r14, r7, r9, r14 @ sum = MAC16_16(sum, x_2, y_2) + LDRGE r8, [r5], #4 + SMLATT r14, r7, r9, r14 @ sum = MAC16_16(sum, x_3, y_3) + LDRGE r7, [r4], #4 + LDRGE r9, [r5], #4 + BGE celt_pitch_xcorr_edsp_process1a_loop4 +celt_pitch_xcorr_edsp_process1a_loop_done: + ADDS r12, r12, #2 + LDRGE r6, [r4], #4 + LDRGE r8, [r5], #4 + @ Stall + SMLABBGE r14, r6, r8, r14 @ sum = MAC16_16(sum, x_0, y_0) + SUBGE r12, r12, #2 + SMLATTGE r14, r6, r8, r14 @ sum = MAC16_16(sum, x_1, y_1) + ADDS r12, r12, #1 + LDRHGE r6, [r4], #2 + LDRHGE r8, [r5], #2 + @ Stall + SMLABBGE r14, r6, r8, r14 @ sum = MAC16_16(sum, *x, *y) + @ maxcorr = max(maxcorr, sum) + CMP r0, r14 + @ xcorr[i] = sum + STR r14, [r2], #4 + MOVLT r0, r14 +celt_pitch_xcorr_edsp_done: + LDMFD sp!, {r4-r11, pc} + .size celt_pitch_xcorr_edsp, .-celt_pitch_xcorr_edsp @ ENDP + + .endif + +@ END: + .section .note.GNU-stack,"",%progbits From 207bf96c2f391b7e36b4b43ac3a4286f807ebcc7 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 5 Jan 2016 15:44:15 +0100 Subject: [PATCH 022/117] update belle-sip --- submodules/belle-sip | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/belle-sip b/submodules/belle-sip index 4d5de406f..98a0bb192 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit 4d5de406f9056025f96b4db7fbf867be9999d826 +Subproject commit 98a0bb19258b2608374313bf1bf05dadb70c5ae8 From 989bba126389ad20482e1719a20c9b5f2758ab58 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Tue, 5 Jan 2016 16:36:23 +0100 Subject: [PATCH 023/117] update linphone submodule (fix lenovo audio issue) --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index f922907fd..a0a801b8a 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit f922907fd8af8ac8926e72d07104d359408c81dc +Subproject commit a0a801b8ad3efab2fff451e952ea9e163798e9a4 From 7451fa260044cdfba017501a772f4ff5502f54fa Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Wed, 6 Jan 2016 14:45:07 +0100 Subject: [PATCH 024/117] update belle-sip and linphone --- submodules/belle-sip | 2 +- submodules/linphone | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/submodules/belle-sip b/submodules/belle-sip index 98a0bb192..9e0cd4a73 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit 98a0bb19258b2608374313bf1bf05dadb70c5ae8 +Subproject commit 9e0cd4a739acf16a55cd3f6f54d99d7748e5c7be diff --git a/submodules/linphone b/submodules/linphone index a0a801b8a..49ad4b81c 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit a0a801b8ad3efab2fff451e952ea9e163798e9a4 +Subproject commit 49ad4b81c6cd5759e74a5f2aa27409a09f3e43fa From 25abce40b7d9b60b406b2da51f20d8b42009e110 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Wed, 6 Jan 2016 16:34:14 +0100 Subject: [PATCH 025/117] update linphone --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index 49ad4b81c..c82307a74 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 49ad4b81c6cd5759e74a5f2aa27409a09f3e43fa +Subproject commit c82307a7472935ea97577929585f256c466757d8 From 6595dd3a1dc4de93712b7de37d72556625adc1f5 Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Wed, 6 Jan 2016 17:42:39 +0100 Subject: [PATCH 026/117] update linphone submodule --- submodules/linphone | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/linphone b/submodules/linphone index c82307a74..60708a53a 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit c82307a7472935ea97577929585f256c466757d8 +Subproject commit 60708a53ab17ccb5084f3ffcbc288edbb5bd3633 From 06f981e538686e197d3b9d21d9a145a1819e523d Mon Sep 17 00:00:00 2001 From: Simon Morlat Date: Sun, 10 Jan 2016 12:26:25 +0100 Subject: [PATCH 027/117] update belle-sip and linphone --- submodules/belle-sip | 2 +- submodules/linphone | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/submodules/belle-sip b/submodules/belle-sip index 9e0cd4a73..be0c7a8bc 160000 --- a/submodules/belle-sip +++ b/submodules/belle-sip @@ -1 +1 @@ -Subproject commit 9e0cd4a739acf16a55cd3f6f54d99d7748e5c7be +Subproject commit be0c7a8bc2a0176dee422e438ca63b4c96baf276 diff --git a/submodules/linphone b/submodules/linphone index 60708a53a..872fe00ed 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 60708a53ab17ccb5084f3ffcbc288edbb5bd3633 +Subproject commit 872fe00eda2c58a082f9c00d1c96fbce6d15c9ae From 8f26fe7a23a89f7a22b346c88cd015eb02652d1d Mon Sep 17 00:00:00 2001 From: Margaux Clerc Date: Tue, 5 Jan 2016 09:31:38 +0100 Subject: [PATCH 028/117] Reworking assistant, add transport in login and fix error display --- res/drawable/assistant_button.xml | 2 + res/drawable/assistant_button_text_color.xml | 7 + res/layout-land/assistant_linphone_login.xml | 4 +- res/layout/assistant.xml | 7 +- res/layout/assistant_account_creation.xml | 357 +++++++++--------- .../assistant_account_creation_activation.xml | 27 +- res/layout/assistant_ec_calibration.xml | 15 +- res/layout/assistant_linphone_login.xml | 180 +++++---- res/layout/assistant_login.xml | 259 +++++++------ res/layout/assistant_remote_provisioning.xml | 39 +- .../assistant_remote_provisioning_login.xml | 2 +- res/layout/assistant_topbar.xml | 32 +- res/layout/assistant_welcome.xml | 128 ++++--- res/layout/main.xml | 2 +- res/layout/status.xml | 8 +- res/values/strings.xml | 49 ++- res/values/styles.xml | 36 +- src/org/linphone/LinphonePreferences.java | 2 +- .../linphone/assistant/AssistantActivity.java | 125 +++--- .../CreateAccountActivationFragment.java | 2 +- .../assistant/CreateAccountFragment.java | 6 +- .../assistant/LinphoneLoginFragment.java | 18 +- src/org/linphone/assistant/LoginFragment.java | 43 ++- .../assistant/RemoteProvisioningFragment.java | 21 +- 24 files changed, 745 insertions(+), 626 deletions(-) create mode 100644 res/drawable/assistant_button_text_color.xml diff --git a/res/drawable/assistant_button.xml b/res/drawable/assistant_button.xml index 77d349fce..5c7dfea0d 100644 --- a/res/drawable/assistant_button.xml +++ b/res/drawable/assistant_button.xml @@ -2,6 +2,8 @@ + diff --git a/res/drawable/assistant_button_text_color.xml b/res/drawable/assistant_button_text_color.xml new file mode 100644 index 000000000..8e05da560 --- /dev/null +++ b/res/drawable/assistant_button_text_color.xml @@ -0,0 +1,7 @@ + + + + + \ No newline at end of file diff --git a/res/layout-land/assistant_linphone_login.xml b/res/layout-land/assistant_linphone_login.xml index da2143e02..96877d420 100644 --- a/res/layout-land/assistant_linphone_login.xml +++ b/res/layout-land/assistant_linphone_login.xml @@ -5,7 +5,7 @@ android:orientation="vertical"> + android:layout_height="40dp" + tools:layout="@layout/status"/> diff --git a/res/layout/assistant_account_creation.xml b/res/layout/assistant_account_creation.xml index d7a17a68c..bccdfec31 100644 --- a/res/layout/assistant_account_creation.xml +++ b/res/layout/assistant_account_creation.xml @@ -1,186 +1,187 @@ - + - + android:padding="30dp" + android:orientation="vertical"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -