From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 2833A43098 for ; Thu, 13 Jan 2022 18:30:05 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E30AE68B558; Thu, 13 Jan 2022 20:30:03 +0200 (EET) Received: from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net [217.70.183.199]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 8CFC668B3AD for ; Thu, 13 Jan 2022 20:29:57 +0200 (EET) Received: from localhost (213-47-68-29.cable.dynamic.surfer.at [213.47.68.29]) (Authenticated sender: michael@niedermayer.cc) by relay9-d.mail.gandi.net (Postfix) with ESMTPSA id 43904FF807 for ; Thu, 13 Jan 2022 18:29:55 +0000 (UTC) Date: Thu, 13 Jan 2022 19:29:55 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20220113182955.GM2829255@pb2> References: <20220113015101.4-1-jamrial@gmail.com> <20220113020913.870-8-jamrial@gmail.com> MIME-Version: 1.0 In-Reply-To: <20220113020913.870-8-jamrial@gmail.com> Subject: Re: [FFmpeg-devel] [PATCH 277/281] ffmpeg: convert to new channel layout-API X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: multipart/mixed; boundary="===============2106298050537947868==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============2106298050537947868== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ZhbBmpMsb0rnZHnU" Content-Disposition: inline --ZhbBmpMsb0rnZHnU Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jan 12, 2022 at 11:09:09PM -0300, James Almer wrote: > Signed-off-by: James Almer > --- > fftools/cmdutils.c | 42 +++++++++++++++--------- > fftools/cmdutils.h | 8 ----- > fftools/ffmpeg.c | 47 ++++++++++++++++---------- > fftools/ffmpeg.h | 7 ++-- > fftools/ffmpeg_filter.c | 52 ++++++++++++++++++++++------- > fftools/ffmpeg_opt.c | 62 ++++++++++++++++++++++++++++++----- > tests/fate/aac.mak | 2 +- > tests/fate/lavf-container.mak | 2 +- > 8 files changed, 155 insertions(+), 67 deletions(-) This or a prior patch introduces crashes (it bisected to this but this is my 2nd testcase the first did not reproduce reliably at all) Thread 1 "ffmpeg_g" received signal SIGSEGV, Segmentation fault. 0x00005555566ed811 in av_vlog (avcl=3D0x5555577400c0, level=3D24, fmt=3D0x5= 555568249e8 "%d frames left in the queue on closing\n", vl=3D0x7fffffffda50= ) at libavutil/log.c:428 428 if (avc && avc->version >=3D (50 << 16 | 15 << 8 | 2) && (gdb) bt #0 0x00005555566ed811 in av_vlog (avcl=3D0x5555577400c0, level=3D24, fmt= =3D0x5555568249e8 "%d frames left in the queue on closing\n", vl=3D0x7fffff= ffda50) at libavutil/log.c:428 #1 0x00005555566ed6bd in av_log (avcl=3D0x5555577400c0, level=3D24, fmt=3D= 0x5555568249e8 "%d frames left in the queue on closing\n") at libavutil/log= =2Ec:411 #2 0x0000555555c320b9 in ff_af_queue_close (afq=3D0x5555576c47c8) at libav= codec/audio_frame_queue.c:39 #3 0x0000555555e84c06 in mp3lame_encode_close (avctx=3D0x5555576bf180) at = libavcodec/libmp3lame.c:86 #4 0x0000555555c373f7 in avcodec_close (avctx=3D0x5555576bf180) at libavco= dec/avcodec.c:489 #5 0x0000555555f7feab in avcodec_free_context (pavctx=3D0x5555576a8858) at= libavcodec/options.c:163 #6 0x000055555569cfe3 in ffmpeg_cleanup (ret=3D1) at fftools/ffmpeg.c:608 #7 0x0000555555694817 in exit_program (ret=3D1) at fftools/cmdutils.c:131 #8 0x000055555569ef1f in do_audio_out (of=3D0x5555576ae2c0, ost=3D0x555557= 6a8800, frame=3D0x5555576bf580) at fftools/ffmpeg.c:1056 #9 0x00005555556a117a in reap_filters (flush=3D0) at fftools/ffmpeg.c:1546 #10 0x00005555556ad8e5 in transcode_step () at fftools/ffmpeg.c:4643 #11 0x00005555556ad9e7 in transcode () at fftools/ffmpeg.c:4687 #12 0x00005555556ae45c in main (argc=3D12, argv=3D0x7fffffffe1c8) at fftool= s/ffmpeg.c:4903 (gdb) print avc->version Cannot access memory at address 0xc1528eb7c0ea0157 make -j32 && gdb --args ./ffmpeg_g -ss 8 -i NeroRecodeSample.mp4 -bitexact = -t 3 -filter_complex '[0:2]scale=3D720:576[v];[v][0:5]overlay' -y file-whit= esubs.avi it appears this file is at: https://samples.ffmpeg.org/MPEG-4/NeroRecodeSample-MP4/ Press [q] to stop, [?] for help [aac @ 0x16fb3540] This stream seems to incorrectly report its last channel= as SCE[1], mapping to LFE[0] [aac @ 0x16fb3540] env_facs_q 253 is invalid =3D=3D21617=3D=3D at 0x12A09F8: VALGRIND_PRINTF_BACKTRACE (valgrind.h:63= 03) =3D=3D21617=3D=3D by 0x12A15B6: av_log_default_callback (log.c:397) =3D=3D21617=3D=3D by 0x12A185D: av_vlog (log.c:432) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0xEED8B6: read_sbr_envelope (aacsbr_template.c:865) =3D=3D21617=3D=3D by 0xEEE22F: read_sbr_single_channel_element (aacsbr_t= emplate.c:983) =3D=3D21617=3D=3D by 0xEEE762: read_sbr_data (aacsbr_template.c:1055) =3D=3D21617=3D=3D by 0xEEEAFD: ff_decode_sbr_extension (aacsbr_template.= c:1144) =3D=3D21617=3D=3D by 0xECD082: decode_extension_payload (aacdec_template= =2Ec:2582) =3D=3D21617=3D=3D by 0xED029B: aac_decode_frame_int (aacdec_template.c:3= 372) =3D=3D21617=3D=3D by 0xED0842: aac_decode_frame (aacdec_template.c:3500) =3D=3D21617=3D=3D by 0x8ABF66: decode_simple_internal (decode.c:329) =3D=3D21617=3D=3D by 0x8ACB62: decode_simple_receive_frame (decode.c:528) =3D=3D21617=3D=3D by 0x8ACC5C: decode_receive_frame_internal (decode.c:5= 48) =3D=3D21617=3D=3D by 0x8ACF38: avcodec_send_packet (decode.c:615) =3D=3D21617=3D=3D by 0x258160: decode (ffmpeg.c:2276) =3D=3D21617=3D=3D by 0x258354: decode_audio (ffmpeg.c:2319) =3D=3D21617=3D=3D by 0x259949: process_input_packet (ffmpeg.c:2638) =3D=3D21617=3D=3D by 0x26138A: process_input (ffmpeg.c:4493) =3D=3D21617=3D=3D by 0x26187E: transcode_step (ffmpeg.c:4633) [aac @ 0x16fb3540] env_facs_q 252 is invalid =3D=3D21617=3D=3D at 0x12A09F8: VALGRIND_PRINTF_BACKTRACE (valgrind.h:63= 03) =3D=3D21617=3D=3D by 0x12A15B6: av_log_default_callback (log.c:397) =3D=3D21617=3D=3D by 0x12A185D: av_vlog (log.c:432) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0xEED8B6: read_sbr_envelope (aacsbr_template.c:865) =3D=3D21617=3D=3D by 0xEEE5AC: read_sbr_channel_pair_element (aacsbr_tem= plate.c:1028) =3D=3D21617=3D=3D by 0xEEE7A7: read_sbr_data (aacsbr_template.c:1060) =3D=3D21617=3D=3D by 0xEEEAFD: ff_decode_sbr_extension (aacsbr_template.= c:1144) =3D=3D21617=3D=3D by 0xECD082: decode_extension_payload (aacdec_template= =2Ec:2582) =3D=3D21617=3D=3D by 0xED029B: aac_decode_frame_int (aacdec_template.c:3= 372) =3D=3D21617=3D=3D by 0xED0842: aac_decode_frame (aacdec_template.c:3500) =3D=3D21617=3D=3D by 0x8ABF66: decode_simple_internal (decode.c:329) =3D=3D21617=3D=3D by 0x8ACB62: decode_simple_receive_frame (decode.c:528) =3D=3D21617=3D=3D by 0x8ACC5C: decode_receive_frame_internal (decode.c:5= 48) =3D=3D21617=3D=3D by 0x8ACF38: avcodec_send_packet (decode.c:615) =3D=3D21617=3D=3D by 0x258160: decode (ffmpeg.c:2276) =3D=3D21617=3D=3D by 0x258354: decode_audio (ffmpeg.c:2319) =3D=3D21617=3D=3D by 0x259949: process_input_packet (ffmpeg.c:2638) =3D=3D21617=3D=3D by 0x26138A: process_input (ffmpeg.c:4493) =3D=3D21617=3D=3D by 0x26187E: transcode_step (ffmpeg.c:4633) [aac @ 0x16fb3540] noise_facs_q 255 is invalid =3D=3D21617=3D=3D at 0x12A09F8: VALGRIND_PRINTF_BACKTRACE (valgrind.h:63= 03) =3D=3D21617=3D=3D by 0x12A15B6: av_log_default_callback (log.c:397) =3D=3D21617=3D=3D by 0x12A185D: av_vlog (log.c:432) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0xEEDE4D: read_sbr_noise (aacsbr_template.c:923) =3D=3D21617=3D=3D by 0xEEE615: read_sbr_channel_pair_element (aacsbr_tem= plate.c:1032) =3D=3D21617=3D=3D by 0xEEE7A7: read_sbr_data (aacsbr_template.c:1060) =3D=3D21617=3D=3D by 0xEEEAFD: ff_decode_sbr_extension (aacsbr_template.= c:1144) =3D=3D21617=3D=3D by 0xECD082: decode_extension_payload (aacdec_template= =2Ec:2582) =3D=3D21617=3D=3D by 0xED029B: aac_decode_frame_int (aacdec_template.c:3= 372) =3D=3D21617=3D=3D by 0xED0842: aac_decode_frame (aacdec_template.c:3500) =3D=3D21617=3D=3D by 0x8ABF66: decode_simple_internal (decode.c:329) =3D=3D21617=3D=3D by 0x8ACB62: decode_simple_receive_frame (decode.c:528) =3D=3D21617=3D=3D by 0x8ACC5C: decode_receive_frame_internal (decode.c:5= 48) =3D=3D21617=3D=3D by 0x8ACF38: avcodec_send_packet (decode.c:615) =3D=3D21617=3D=3D by 0x258160: decode (ffmpeg.c:2276) =3D=3D21617=3D=3D by 0x258354: decode_audio (ffmpeg.c:2319) =3D=3D21617=3D=3D by 0x259949: process_input_packet (ffmpeg.c:2638) =3D=3D21617=3D=3D by 0x26138A: process_input (ffmpeg.c:4493) =3D=3D21617=3D=3D by 0x26187E: transcode_step (ffmpeg.c:4633) Audio encoding failed =3D=3D21617=3D=3D at 0x12A09F8: VALGRIND_PRINTF_BACKTRACE (valgrind.h:63= 03) =3D=3D21617=3D=3D by 0x12A15B6: av_log_default_callback (log.c:397) =3D=3D21617=3D=3D by 0x12A185D: av_vlog (log.c:432) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0x252F14: do_audio_out (ffmpeg.c:1055) =3D=3D21617=3D=3D by 0x255179: reap_filters (ffmpeg.c:1546) =3D=3D21617=3D=3D by 0x2618E4: transcode_step (ffmpeg.c:4643) =3D=3D21617=3D=3D by 0x2619E6: transcode (ffmpeg.c:4687) =3D=3D21617=3D=3D by 0x26245B: main (ffmpeg.c:4903) =3D=3D21617=3D=3D Invalid read of size 4 =3D=3D21617=3D=3D at 0x12A1811: av_vlog (log.c:428) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0x7E60B8: ff_af_queue_close (audio_frame_queue.c:39) =3D=3D21617=3D=3D by 0xA38C05: mp3lame_encode_close (libmp3lame.c:86) =3D=3D21617=3D=3D by 0x7EB3F6: avcodec_close (avcodec.c:489) =3D=3D21617=3D=3D by 0xB33EAA: avcodec_free_context (options.c:163) =3D=3D21617=3D=3D by 0x250FE2: ffmpeg_cleanup (ffmpeg.c:608) =3D=3D21617=3D=3D by 0x248816: exit_program (cmdutils.c:131) =3D=3D21617=3D=3D by 0x252F1E: do_audio_out (ffmpeg.c:1056) =3D=3D21617=3D=3D by 0x255179: reap_filters (ffmpeg.c:1546) =3D=3D21617=3D=3D by 0x2618E4: transcode_step (ffmpeg.c:4643) =3D=3D21617=3D=3D by 0x2619E6: transcode (ffmpeg.c:4687) =3D=3D21617=3D=3D by 0x26245B: main (ffmpeg.c:4903) =3D=3D21617=3D=3D Address 0xc1528eb7c0ea0157 is not stack'd, malloc'd or (= recently) free'd =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D Process terminating with default action of signal 11 (SIG= SEGV) =3D=3D21617=3D=3D General Protection Fault =3D=3D21617=3D=3D at 0x12A1811: av_vlog (log.c:428) =3D=3D21617=3D=3D by 0x12A16BC: av_log (log.c:411) =3D=3D21617=3D=3D by 0x7E60B8: ff_af_queue_close (audio_frame_queue.c:39) =3D=3D21617=3D=3D by 0xA38C05: mp3lame_encode_close (libmp3lame.c:86) =3D=3D21617=3D=3D by 0x7EB3F6: avcodec_close (avcodec.c:489) =3D=3D21617=3D=3D by 0xB33EAA: avcodec_free_context (options.c:163) =3D=3D21617=3D=3D by 0x250FE2: ffmpeg_cleanup (ffmpeg.c:608) =3D=3D21617=3D=3D by 0x248816: exit_program (cmdutils.c:131) =3D=3D21617=3D=3D by 0x252F1E: do_audio_out (ffmpeg.c:1056) =3D=3D21617=3D=3D by 0x255179: reap_filters (ffmpeg.c:1546) =3D=3D21617=3D=3D by 0x2618E4: transcode_step (ffmpeg.c:4643) =3D=3D21617=3D=3D by 0x2619E6: transcode (ffmpeg.c:4687) =3D=3D21617=3D=3D by 0x26245B: main (ffmpeg.c:4903) =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D HEAP SUMMARY: =3D=3D21617=3D=3D in use at exit: 3,463,746 bytes in 473 blocks =3D=3D21617=3D=3D total heap usage: 1,923 allocs, 1,450 frees, 9,590,510 = bytes allocated =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D 5,888 bytes in 16 blocks are possibly lost in loss record= 159 of 180 =3D=3D21617=3D=3D at 0x4C33B25: calloc (in /usr/lib/valgrind/vgpreload_m= emcheck-amd64-linux.so) =3D=3D21617=3D=3D by 0x4013646: allocate_dtv (dl-tls.c:286) =3D=3D21617=3D=3D by 0x4013646: _dl_allocate_tls (dl-tls.c:530) =3D=3D21617=3D=3D by 0xCB4F227: allocate_stack (allocatestack.c:627) =3D=3D21617=3D=3D by 0xCB4F227: pthread_create@@GLIBC_2.2.5 (pthread_cre= ate.c:644) =3D=3D21617=3D=3D by 0xB6C3FB: init_thread (pthread_frame.c:842) =3D=3D21617=3D=3D by 0xB6C625: ff_frame_thread_init (pthread_frame.c:898) =3D=3D21617=3D=3D by 0xB69E97: ff_thread_init (pthread.c:81) =3D=3D21617=3D=3D by 0x7EAC52: avcodec_open2 (avcodec.c:330) =3D=3D21617=3D=3D by 0x25AA65: init_input_stream (ffmpeg.c:2922) =3D=3D21617=3D=3D by 0x25D48C: transcode_init (ffmpeg.c:3634) =3D=3D21617=3D=3D by 0x261924: transcode (ffmpeg.c:4658) =3D=3D21617=3D=3D by 0x26245B: main (ffmpeg.c:4903) =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D LEAK SUMMARY: =3D=3D21617=3D=3D definitely lost: 0 bytes in 0 blocks =3D=3D21617=3D=3D indirectly lost: 0 bytes in 0 blocks =3D=3D21617=3D=3D possibly lost: 5,888 bytes in 16 blocks =3D=3D21617=3D=3D still reachable: 3,457,858 bytes in 457 blocks =3D=3D21617=3D=3D suppressed: 0 bytes in 0 blocks =3D=3D21617=3D=3D Reachable blocks (those to which a pointer was found) are= not shown. =3D=3D21617=3D=3D To see them, rerun with: --leak-check=3Dfull --show-leak-= kinds=3Dall =3D=3D21617=3D=3D=20 =3D=3D21617=3D=3D For counts of detected and suppressed errors, rerun with:= -v =3D=3D21617=3D=3D ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 fr= om 0) thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB In a rich man's house there is no place to spit but his face. -- Diogenes of Sinope --ZhbBmpMsb0rnZHnU Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEIAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCYeBvnwAKCRBhHseHBAsP q9QRAJ92VQUQHFJWcizix2BmmHc7nLuzWACfZ5vGzS+6eBrM67c5aJ+KOmLaJKw= =8QFN -----END PGP SIGNATURE----- --ZhbBmpMsb0rnZHnU-- --===============2106298050537947868== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". --===============2106298050537947868==--