From: Stephen Hutchinson <qyot27@gmail.com>
To: ffmpeg-devel@ffmpeg.org
Subject: Re: [FFmpeg-devel] [PATCH] avformat/avisynth: remove atexit() handler
Date: Wed, 17 Jul 2024 18:10:32 -0400
Message-ID: <65f04509-b714-4dc8-9856-d32969b9a23d@gmail.com> (raw)
In-Reply-To: <347ebb6c-1239-4e64-9ef5-d94a4dab28fe@gmail.com>
On 7/7/24 1:46 PM, Stephen Hutchinson wrote:
> On 7/7/24 9:50 AM, Andreas Rheinhardt wrote:
>>
>> avisynth_context_destroy() is currently always called while holding the
>> lock (i.e. avisynth_mutex). Is this even necessary? It is clear that
>> avisynth_load_library() (and the check for whether it should be called)
>> need the lock, but does anything else (like
>> avs_create_script_environment) really need it?
>>
>
> Threading control is a topic that definitely goes over my head, so
> my honest answer would be that I don't know. But what I would say is
> that if I correctly understand the order of execution inside the
> demuxer, library, and script environment, AviSynth loading its own
> plugins occurs after avs_create_script_environment is called in the
> client program.
>
> If avs_load_library and its check need the lock in place,
> is it supposed to be assumed that then AviSynth handles
> loading/unloading its plugins purely on its own without the
> overarching lock, or is that cascaded loading something that
> needs the lock in place throughout the process (because
> avisynth_context_destroy is what ultimately calls
> avs_delete_script_environment and unloads whatever plugins were
> loaded by AviSynth)?
I've sent a second patch to remove the lock requirement in
avisynth_read_close.
The atexit patch was separate anyway, and if there's no
objections raised, I'll push that one in a day or two,
or wait a little longer and push both at the same time
if the lock change is fine.
_______________________________________________
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".
next prev parent reply other threads:[~2024-07-17 22:10 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-07 3:25 Stephen Hutchinson
2024-07-07 13:50 ` Andreas Rheinhardt
2024-07-07 17:46 ` Stephen Hutchinson
2024-07-17 22:10 ` Stephen Hutchinson [this message]
2024-07-17 22:05 ` [FFmpeg-devel] [PATCH 2/2] avformat/avisynth: remove mutex lock from read_close Stephen Hutchinson
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=65f04509-b714-4dc8-9856-d32969b9a23d@gmail.com \
--to=qyot27@gmail.com \
--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