[Bug 787311] New: vtenc memory leak
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Tue Sep 5 13:45:08 UTC 2017
https://bugzilla.gnome.org/show_bug.cgi?id=787311
Bug ID: 787311
Summary: vtenc memory leak
Classification: Platform
Product: GStreamer
Version: 1.x
OS: Linux
Status: NEW
Severity: normal
Priority: Normal
Component: gst-plugins-bad
Assignee: gstreamer-bugs at lists.freedesktop.org
Reporter: lists at svrinformatica.it
QA Contact: gstreamer-bugs at lists.freedesktop.org
GNOME version: ---
Created attachment 359186
--> https://bugzilla.gnome.org/attachment.cgi?id=359186&action=edit
add logs
Starting stopping a pipeline using vtenc in my application I see a memory
increase at each cycle. If I replace vtenc_h264 with openh264enc no memory is
leaked. Analyzing the leak using istruments shows that one or more
CMSampleBuffer are leaked.
I added some logs to vtenc to understand what happens,
1) vtenc clean cur_outframes only on finish that based on my understanding
should be triggerd by an EOS, so if you set the pipeline to NULL without
sending an EOS as I do in my application, finish is not called
2) without calling finish gst_vtenc_stop call g_async_queue_unref
(self->cur_outframes); but the queue size is > 0
I'll try to send a patch later.
With the attached patch you can see logs such as this:
0:00:14.943205000 982 0x3634138 TRACE vtenc
vtenc.c:1240:gst_vtenc_encode_frame:<stream_vencoder> encoding frame 294
0:00:14.981574000 982 0x36765c0 DEBUG vtenc
vtenc.c:518:gst_vtenc_stop:<stream_vencoder> stopping
0:00:14.981618000 982 0x36765c0 DEBUG vtenc
vtenc.c:521:gst_vtenc_stop:<stream_vencoder> destroy session
0:00:14.981643000 982 0x36765c0 DEBUG vtenc
vtenc.c:891:gst_vtenc_destroy_session:<stream_vencoder> destroy session
0:00:14.985491000 982 0x3677340 TRACE vtenc
vtenc.c:1322:gst_vtenc_enqueue_buffer:<stream_vencoder> encoded frame 294
0:00:15.001487000 982 0x36765c0 DEBUG vtenc
vtenc.c:539:gst_vtenc_stop:<stream_vencoder> unref async queue, size 1
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list