From: Mark Thompson <sw@jkqxz.net> To: ffmpeg-devel@ffmpeg.org Subject: Re: [FFmpeg-devel] [PATCH 01/11] avcodec/vulkan_encode_h264: Fix memleak on error Date: Sun, 1 Jun 2025 21:45:48 +0100 Message-ID: <dacaed25-1ba0-42fa-8b4e-56fe8fd982da@jkqxz.net> (raw) In-Reply-To: <GV1P250MB0737150B57AB1453E4F40F628F8E2@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> On 06/05/2025 00:37, Andreas Rheinhardt wrote: > Patches attached. > > - Andreas > > > [PATCH 05/11] avcodec/cbs,cbs_jpeg: Split ff_cbs_append_unit_data() Suggest assert0 for all error cases in cbs generic code, since none of them are inner-loop performance sensitive. Patch looks good. > [PATCH 06/11] avcodec/cbs: Allow to avoid refcounting/data copying Having force_refcounting set to one at init makes me think the sense of it should be other way around? ("disable_refcounting"?) Would it be sensible for the new checks for data_ref to assert that you are not in a refcounting case? Also wondering whether we should have a new helper function something like: int ff_cbs_make_unit_data_ref(SomethingContexty *c, AVBufferRef **ref, const CodedBitstreamUnit *unit) { av_assert0(!*ref); if (unit->data_ref) { *ref = av_buffer_ref(unit->data_ref); if (!*ref) return AVERROR(ENOMEM); } else { av_assert0(c->disable_refcounting); } return 0; } to avoid the repeated code you add in the various codec files. > [PATCH 07/11] avcodec/apv_parser: Don't use dummy AVBufferRef* > [PATCH 08/11] Revert "avcodec/cbs: add an AVBufferRef input argument to ff_cbs_read()" Yes, this ends up being a nicer answer. > [PATCH 09/11] avcodec/av1_parser: Avoid copying data It's not obvious that this does the right thing with the persistent reference to the sequence header object. Can you explain further how that is working? > [PATCH 10/11] avcodec/cbs_bsf: Avoid creating unnecessary references Does this not add a significant new constraint on all bsfs using the cbs_bsf structure? It's unclear to me whether works in all cases such as those where new units are added. > [PATCH 11/11] avcodec/bsf/trace_headers: Avoid creating unnecessary references Same thought as 9 in other codecs, but fine if 9 is. Thanks, - Mark _______________________________________________ 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".
prev parent reply other threads:[~2025-06-01 20:46 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2025-05-05 23:37 Andreas Rheinhardt 2025-05-07 13:16 ` Lynne 2025-05-25 2:49 ` James Almer 2025-05-25 2:52 ` James Almer 2025-06-01 20:45 ` Mark Thompson [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=dacaed25-1ba0-42fa-8b4e-56fe8fd982da@jkqxz.net \ --to=sw@jkqxz.net \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git