On Tue, Oct 18, 2022 at 6:54 PM Anton Khirnov <an...@khirnov.net> wrote:
> +static void thread_set_name(PerThreadContext *p)
> +{
> +    AVCodecContext *avctx = p->avctx;
> +    int idx = p - p->parent->threads;
> +    char name[16];
> +
> +    snprintf(name, sizeof(name), "d:%.7s:ft%d", avctx->codec->name, idx);
> +
> +    ff_thread_setname(name);
> +}

How about having some kind of prefix to indicate that those are
libavcodec threads?

Could be helpful in a scenario where a process has threads spawned by
35 different libraries.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to