Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playback of high bitrate FLAC streams may fail (pre Android-N) #4057

Closed
tangmingscau opened this issue Mar 30, 2018 · 16 comments
Closed

Playback of high bitrate FLAC streams may fail (pre Android-N) #4057

tangmingscau opened this issue Mar 30, 2018 · 16 comments

Comments

@tangmingscau
Copy link

tangmingscau commented Mar 30, 2018

I pulled the latest 2.7.2 code, which restored the bug of #3514, but it caused a more serious crash. When I played the FLAC music with larger rate, APP native crash occurred.

2/? I/DEBUG: Revision: '0'
03-30 14:22:27.994 962-962/? I/DEBUG: pid: 1895, tid: 2505, name: gle.raw.decoder  >>> com.google.android.exoplayer2.demo <<<
03-30 14:22:27.994 962-962/? I/DEBUG: signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
03-30 14:22:28.094 962-962/? I/DEBUG:     r0 00000000  r1 000009c9  r2 00000006  r3 00000000
03-30 14:22:28.094 962-962/? I/DEBUG:     r4 6b514dd8  r5 00000006  r6 00000000  r7 0000010c
03-30 14:22:28.094 962-962/? I/DEBUG:     r8 6eaec92c  r9 69522500  sl 6e39e6d0  fp 00000000
03-30 14:22:28.094 962-962/? I/DEBUG:     ip 000009c9  sp 6b514810  lr 400db07b  pc 400e9f9c  cpsr 00030010
03-30 14:22:28.094 962-962/? I/DEBUG:     d0  4874756f20284520  d1  6e3e2d7265646134
03-30 14:22:28.094 962-962/? I/DEBUG:     d2  6e654c636f6c6c39  d3  65646165486e6931
03-30 14:22:28.094 962-962/? I/DEBUG:     d4  6c6c69466e3e2d72  d5  6620296e654c6465
03-30 14:22:28.094 962-962/? I/DEBUG:     d6  33203a64656c6961  d7  2e73762038363732
03-30 14:22:28.094 962-962/? I/DEBUG:     d8  0000000000000000  d9  0000000000000000
03-30 14:22:28.094 962-962/? I/DEBUG:     d10 0000000000000000  d11 0000000000000000
03-30 14:22:28.094 962-962/? I/DEBUG:     d12 0000000000000000  d13 0000000000000000
03-30 14:22:28.094 962-962/? I/DEBUG:     d14 0000000000000000  d15 0000000000000000
03-30 14:22:28.094 962-962/? I/DEBUG:     d16 66768528695453e8  d17 667685286b803db0
03-30 14:22:28.094 962-962/? I/DEBUG:     d18 667685286e7f25c8  d19 667685286954afa8
03-30 14:22:28.094 962-962/? I/DEBUG:     d20 667685286e7f4730  d21 667685286e7fefc0
03-30 14:22:28.094 962-962/? I/DEBUG:     d22 667685286954ddc8  d23 667685286b404d00
03-30 14:22:28.094 962-962/? I/DEBUG:     d24 0000000000000000  d25 ffffffffffffffff
03-30 14:22:28.094 962-962/? I/DEBUG:     d26 3fdb6db71408e660  d27 0000000000000002
03-30 14:22:28.094 962-962/? I/DEBUG:     d28 ffffffffffffffff  d29 0000000000000007
03-30 14:22:28.094 962-962/? I/DEBUG:     d30 fff0000000000000  d31 0000000005000004
03-30 14:22:28.094 962-962/? I/DEBUG:     scr 60000010
03-30 14:22:28.094 962-962/? I/DEBUG: backtrace:
03-30 14:22:28.094 962-962/? I/DEBUG:     #00  pc 00021f9c  /system/lib/libc.so (tgkill+12)
03-30 14:22:28.094 962-962/? I/DEBUG:     #01  pc 00013077  /system/lib/libc.so (pthread_kill+50)
03-30 14:22:28.094 962-962/? I/DEBUG:     #02  pc 0001326f  /system/lib/libc.so (raise+10)
03-30 14:22:28.094 962-962/? I/DEBUG:     #03  pc 00011fd9  /system/lib/libc.so
03-30 14:22:28.094 962-962/? I/DEBUG:     #04  pc 00021850  /system/lib/libc.so (abort+4)
03-30 14:22:28.094 962-962/? I/DEBUG:     #05  pc 0000148f  /system/lib/liblog.so (__android_log_assert+86)
03-30 14:22:28.094 962-962/? I/DEBUG:     #06  pc 000021c7  /system/lib/libstagefright_soft_rawdec.so (android::SoftRaw::onQueueFilled(unsigned long)+118)
03-30 14:22:28.094 962-962/? I/DEBUG:     #07  pc 00012925  /system/lib/libstagefright_omx.so (android::SimpleSoftOMXComponent::onMessageReceived(android::sp<android::AMessage> const&)+340)
03-30 14:22:28.094 962-962/? I/DEBUG:     #08  pc 000129f3  /system/lib/libstagefright_omx.so
03-30 14:22:28.094 962-962/? I/DEBUG:     #09  pc 0000944d  /system/lib/libstagefright_foundation.so (android::ALooperRoster::deliverMessage(android::sp<android::AMessage> const&)+152)
03-30 14:22:28.094 962-962/? I/DEBUG:     #10  pc 00008f25  /system/lib/libstagefright_foundation.so (android::ALooper::loop()+196)
03-30 14:22:28.094 962-962/? I/DEBUG:     #11  pc 0000e991  /system/lib/libutils.so (android::Thread::_threadLoop(void*)+104)
03-30 14:22:28.094 962-962/? I/DEBUG:     #12  pc 0000e533  /system/lib/libutils.so
03-30 14:22:28.094 962-962/? I/DEBUG:     #13  pc 0000d240  /system/lib/libc.so (__thread_entry+72)
03-30 14:22:28.094 962-962/? I/DEBUG:     #14  pc 0000d3dc  /system/lib/libc.so (pthread_create+240)
03-30 14:22:28.094 962-962/? I/DEBUG: stack:
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147d0  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147d4  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147d8  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147dc  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147e0  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147e4  000003ff  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147e8  6b7b8478  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147ec  6b7c0ea8  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147f0  6eaec8ac  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147f4  6eaec92c  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147f8  69522500  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b5147fc  6e39e6d0  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514800  400c407d  /system/lib/liblog.so
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514804  69759730  /system/lib/libstagefright_soft_rawdec.so
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514808  6b51487c  [stack:2505]
03-30 14:22:28.094 962-962/? I/DEBUG:          6b51480c  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:     #00  6b514810  6b514dd8  [stack:2505]
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514814  00000006  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514818  00000000  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b51481c  000009c9  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514820  000009c9  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514824  400db07b  /system/lib/libc.so (pthread_kill+54)
03-30 14:22:28.094 962-962/? I/DEBUG:     #01  6b514828  6b514dd0  [stack:2505]
03-30 14:22:28.094 962-962/? I/DEBUG:          6b51482c  00000006  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514830  6b7b8478  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514834  6b7c0ea8  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514838  6eaec8ac  
03-30 14:22:28.094 962-962/? I/DEBUG:          6b51483c  400db273  /system/lib/libc.so (raise+14)
03-30 14:22:28.094 962-962/? I/DEBUG:     #02  6b514840  6b51484c  [stack:2505]
03-30 14:22:28.094 962-962/? I/DEBUG:          6b514844  400d9fdd  /system/lib/libc.so
03-30 14:22:28.104 962-962/? I/DEBUG: memory near r4:
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514db8 6958aec8 69786bb0 6b3f9dd8 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514dc8 00000078 400d53e0 6b514dd0 69786bb0  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514dd8 00000000 00000000 00000000 9b7a327a  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514de8 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514df8 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e08 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e18 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e28 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e38 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e48 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e58 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e68 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e78 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e88 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514e98 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     6b514ea8 00000000 00000000 00000000 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG: memory near r8:
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec90c 6663e7bd 00000000 00000002 66646a88  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec91c 6e39e6d0 00000004 00000000 00000008  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec92c 66646a78 6e7f0238 00000000 6bc0884d  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec93c 00000000 69582e28 6e3f4930 00000020  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec94c 000000f9 6b4053c8 6d8ac4f0 65676170  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec95c 2e326461 676f6f67 7973656c 6369646e  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec96c 6f697461 6f632e6e 61702f6d 64616567  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec97c 6e65672f 3430325f 6165663f 65727574  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec98c 7474613d 75626972 6e6f6974 26766944  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec99c 3d64696c 73263835 3d766b64 2e332e68  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9ac 302e3834 6e463225 646e612e 64696f72  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9bc 372e332e 3225342e 6d6f6346 6f6f672e  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9cc 2e656c67 72646e61 2e64696f 706f7865  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9dc 6579616c 642e3272 266f6d65 32333d65  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9ec 33323134 25333430 39344332 34343635  
03-30 14:22:28.104 962-962/? I/DEBUG:     6eaec9fc 26393030 693d6469 6e5f616d 76697461  
03-30 14:22:28.104 962-962/? I/DEBUG: memory near r9:
03-30 14:22:28.104 962-962/? I/DEBUG:     695224e0 00000001 ff000000 00000001 0000003b  
03-30 14:22:28.104 962-962/? I/DEBUG:     695224f0 00000001 00000020 6abd0000 00002000  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522500 6b7c0ea8 00000101 6952be28 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522510 697828a0 00000000 69780e10 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522520 00000000 00000023 00000c00 00000600  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522530 6b7bb9a0 6b7972d8 00000000 6b7d0250  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522540 00000020 00000153 69522501 6d86c890  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522550 00000000 6b411b30 69514808 00000002  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522560 00000298 0000001a 69514805 695147e8  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522570 00000000 695231d8 6bc7fea7 00000000  
03-30 14:22:28.104 962-962/? I/DEBUG:     69522580 00000000 40116248 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     69522590 00000000 00000000 00000000 50000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     695225a0 76766700 86c22db1 7ea083d0 4bba7ea6  
03-30 14:22:28.114 962-962/? I/DEBUG:     695225b0 695225a0 695225a0 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     695225c0 69522600 00000000 00000050 695225bc  
03-30 14:22:28.114 962-962/? I/DEBUG:     695225d0 695225bc 00000000 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG: memory near sl:
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e6b0 00000000 00000000 00000000 0000003b  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e6c0 00000001 00000020 00000000 4047eade  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e6d0 6b7c1940 dead1001 6b78cca0 00000001  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e6e0 6d86f848 00000001 6b75cee8 00000001  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e6f0 0000000c 0000003b 4018de34 4018de5c  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e700 00000000 00000008 00008000 00008000  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e710 6b7baab8 6eaf1158 4018debc 6e9f7348  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e720 00000000 404832dc 00000038 00000023  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e730 00000001 0000000c 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e740 00300030 0030003a 00000030 00000073  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e750 00088b88 00000001 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e760 00000000 00000000 00000001 000088e4  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e770 000088b9 00000000 00000300 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e780 00000000 00000000 00000040 69551508  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e790 00000000 00000000 00000000 00000003  
03-30 14:22:28.114 962-962/? I/DEBUG:     6e39e7a0 6977b934 699d7d04 00000000 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG: memory near sp:
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5147f0 6eaec8ac 6eaec92c 69522500 6e39e6d0  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514800 400c407d 69759730 6b51487c 00000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514810 6b514dd8 00000006 00000000 000009c9  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514820 000009c9 400db07b 6b514dd0 00000006  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514830 6b7b8478 6b7c0ea8 6eaec8ac 400db273  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514840 6b51484c 400d9fdd 00000000 ffffffdf  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514850 00000000 00000000 00000000 9b7a327a  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514860 00000000 69759730 6b7b8478 400e9854  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514870 400c407d 400c4493 6b514c8c 6d617266  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514880 726f7765 612f736b 656d2f76 2f616964  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b514890 7362696c 65676174 67697266 632f7468  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5148a0 6365646f 61722f73 6f532f77 61527466  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5148b0 70632e77 38313a70 48432031 5f4b4345  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5148c0 20284547 4874756f 65646165 6e3e2d72  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5148d0 6f6c6c41 6e654c63 486e692c 65646165  
03-30 14:22:28.114 962-962/? I/DEBUG:     6b5148e0 6e3e2d72 6c6c6946 654c6465 6620296e  
03-30 14:22:28.114 962-962/? I/DEBUG: code around pc:
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9f7c e8bd00f0 e3700a01 912fff1e e2600000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9f8c ea006e7c e92d50f0 e3a07f43 ef000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9f9c e8bd50f0 e3700a01 912fff1e e2600000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9fac ea006e74 e92d50f0 e3a070ee ef000000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9fbc e8bd50f0 e3700a01 912fff1e e2600000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9fcc ea006e6c e1520003 8a00008c f5d1f040  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9fdc e92d4001 e3520010 3a000024 e2603000  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9fec e213300f 0a00000e e0422003 e1b0cf83  
03-30 14:22:28.114 962-962/? I/DEBUG:     400e9ffc 44d1e001 44c0e001 24d1c001 24d1e001  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea00c 24c0c001 24c0e001 e1b0ce83 aa000001  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea01c f4a1030d f480031d 3a000001 f421070d  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea02c f400071d e2522040 3a000006 f421020d  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea03c f421420d f5d1f100 e2522040 f400022d  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea04c f400422d 2afffff8 e2922020 3a000002  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea05c f421020d e2422020 f400022d e2822020  
03-30 14:22:28.114 962-962/? I/DEBUG:     400ea06c e3120010 0a000001 f4210a0d f4000a2d  
03-30 14:22:28.114 962-962/? I/DEBUG: code around lr:
03-30 14:22:28.114 962-962/? I/DEBUG:     400db058 4b11ec2a e010447b d10e42bb 6a1f480f  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db068 f7fb4478 f00deca2 4639e9ca f00e462a  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db078 3001ef8c 2500d00a 681be009 d1eb2b00  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db088 25034807 f7fb4478 e000ec90 60266825  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db098 bdf84628 0003b348 0003b33c 0003b334  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0a8 0003b310 bf82f7ff 47f0e92d 4a394b38  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0b8 589e447b 6833b08a 460d4607 f0019309  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0c8 46b1f9f5 f8d04604 2d008000 4628d04a  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0d8 fef2f00f 4606280f f7ffd846 4287ffe3  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0e8 200fd106 f00d4629 2800e898 e032d03d  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db0f8 44784829 ebd6f7fb 44784828 42b8e015  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db108 6a07d113 44784826 ec4ef7fb 463b4a25  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db118 447a2120 f013a801 2101fab7 f01aa801  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db128 1c43fdb5 d1044607 6800e015 d1e62800  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db138 4638e023 46324629 e8d2f00d 3ffff1b0  
03-30 14:22:28.114 962-962/? I/DEBUG:     400db148 d1024682 29046821 4638d0f3 e922f00d

demo-withExtensions-debug.apk.zip

@tangmingscau
Copy link
Author

I've been sending you the music on the #4055 question.

@ojw28
Copy link
Contributor

ojw28 commented Apr 2, 2018

What device does this occur on? It looks likely that this is a device specific issue. Please capture and attach a full bug report, as is clearly requested in the issue template.

@ojw28 ojw28 self-assigned this Apr 2, 2018
@tangmingscau
Copy link
Author

there is a complete Log
logcat.txt

@ojw28
Copy link
Contributor

ojw28 commented Apr 3, 2018

I'm fairly sure this is a device specific issue. You should report it to the device manufacturer. Do you know if the device also has OMX.google.raw.decoder? If so it may be possible to work around the issue by blacklisting gle.raw.decoder.

@tangmingscau
Copy link
Author

I saw the flow of FLAC playing, and finally FLAC music was broadcast to Android system in audio_raw mode, and the Android system had a soft solution OMX.google.raw.decoder. Or the FLAC bitstream is too high to cause the Android system to fail to play, causing the internal error of the Android system. But I don't have the source code of Android system, so I can't provide more information to you. Can you use other machine to reappear the problem?

@tangmingscau
Copy link
Author

@ojw28
Copy link
Contributor

ojw28 commented Apr 4, 2018

The decoder that's failing is gle.raw.decoder, not OMX.google.raw.decoder. I'm asking whether OMX.google.raw.decoder is also present on the device, in which case we could probably use that decoder instead.

I think this issue is likely device specific. The device you're using looks pretty obscure to me. Is that accurate?

@tangmingscau
Copy link
Author

The source code location to the problem is the 181 line of http://androidxref.com/4.4.4_r1/xref/frameworks/av/media/libstagefright/codecs/raw/SoftRaw.cpp, because the maximum length of inputBuffer allowed by the system is 37268, while the music one frame data is 49152, and how I allow the system to allow the maximum length inputBuffer is 64K, then the music is It can be played normally. So when ExoPlayer enters inputBuffer, it is necessary to judge the maximum inputbuffer allowed by the Android system. Only in this way, the system will not run out. This problem should be the common problem of Android.

@ojw28
Copy link
Contributor

ojw28 commented Apr 11, 2018

This issue is really confusing. The decoder with the issue in the initial report does not appear to be the decoder you're now referring to. Are there two issues that are being conflated here?

The issue you refer to in your most recent post is fixed in more recent versions of Android (definitely by Nougat, I'm less sure about Marshmallow).

@tangmingscau
Copy link
Author

The first thing to confirm is to use OMX.google.raw.decoder, because flacExtractor is to output a PCM flow to play the Android system. Maybe this native crash error Log output is problematic, showing gle.raw.decoder. This is not related to the Android version of the system. I checked the data. It looks like the latest version of Android system inputbuffer is also 32K. So in this case, either do not export PCM stream to Android system, or native crash will happen

@tangmingscau
Copy link
Author

But the occurrence of crash is a disastrous consequence for app, so I suggest Exoplayer to judge the system inputbuffer.

@ojw28
Copy link
Contributor

ojw28 commented Apr 13, 2018

It looks like the latest version of Android system inputbuffer is also 32K.

The problem isn't that the input buffer is only 32K. I took a more detailed look at logcat.txt attached further up, and it indicates the input buffer is sized correctly at 49K. The problem is that the output buffer is only 32K, where-as it needs to be the same size as the input buffer:

CHECK_GE( outHeader->nAllocLen,inHeader->nFilledLen) failed: 32768 vs. 49152

This issue was fixed in Android N, in this change.

So what we need to do to fix this issue, is for Marshmallow and earlier, either:

  1. Fail less badly, by refusing to configure this decoder with a max input size greater than 32K.
  2. Add a workaround that'll fragment each sample into multiple 32K input buffers.

ojw28 added a commit that referenced this issue May 7, 2018
Playback will still fail if an input sample is larger
than 32K, but will now fail gracefully.

Issue: #4057

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=193951955
@ojw28
Copy link
Contributor

ojw28 commented May 7, 2018

(1) is implemented as described in my response above. We've not done (2), and this is likely to be considered low priority.

@ojw28 ojw28 changed the title play flac crash Playback of high bitrate FLAC streams may fail (pre Android-N) May 7, 2018
@ojw28
Copy link
Contributor

ojw28 commented Apr 16, 2019

I don't think we're ever going to do (2). It's not high enough priority. @andrewlewis - Although for a different use case, is the audio offload work likely to produce a code path that can be used to bypass the decoder and "just fix this"? If not, I think we can close this.

@ojw28 ojw28 assigned andrewlewis and unassigned ojw28 Apr 16, 2019
@andrewlewis
Copy link
Collaborator

Yes. I experimented with using the raw decoder path for offload to keep the code simple, but unfortunately this used significantly more power than fully bypassing the MediaCodec path. So this issue should be fixed pre-Android N as part of the audio offload work.

@ojw28
Copy link
Contributor

ojw28 commented Aug 12, 2020

This should be fixed by 5342576.

@ojw28 ojw28 closed this as completed Aug 12, 2020
@google google locked and limited conversation to collaborators Oct 12, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants