cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
728 Views
Registered: ‎08-20-2019

Slow read access to GStreamer GstBuffer when streamed from VDMA to v4l2src

We are currently using the 2019.1 build of Vivada and have successfully streamed 1024x768 RGB video to gstreamer using a VDMA block at 30 Hz.  Here is the gstreamer pipeline:

gst-launch-1.0 -e v4l2src device=/dev/video0 do-timestamp=true io-mode=4 ! "video/x-raw, framerate=(fraction)30/1, width=(int)1024, height=(int)768" ! videoconvert ! kmssink bus-id=fd4a0000.zynqmp-display fullscreen-overlay=1 sync=false
 
When I add my gstreamer plugin into the pipeline (before videoconvert) and I try to copy the raw data in the GstBuffer (via GstMemory, GstMapInfo) interfaces, the memcpy of the buffer is taking 3 times longer than copying from other PS allocated RAM of equal size.  How can I force gstreamer to receive the buffer from VDMA into RAM that the PS can quickly read?  Right now I believe the memcpy is copying from external DDR RAM that is not cacheable which is why it is taking 3x longer.
 
Any insight is greatly appreciated!
Tags (1)
0 Kudos
6 Replies
Highlighted
Moderator
Moderator
642 Views
Registered: ‎11-09-2015

HI roland.ahearn@elbitsystems-us.com 

You need to investigate in your system to know where is the bottleneck.I am not sure how gstreamer will deal with the memory. This is not really something Xilinx can provide an answer as gstreamer is not a Xilinx utility

Are you using the PS DDR? You might want to look at the Quality of Service (QoS) parameter from the UG1085 and give more priority to your APU in read. This is the only thing I can think of.


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Highlighted
Teacher
Teacher
626 Views
Registered: ‎06-16-2013

Hi roland.ahearn@elbitsystems-us.com 

 

Did you investigate bottle neck by using gst-shark(*1) and gstreamer_timestamp_marking plugin ?

If no, I suggest you to use them, first.

 

BTW,did you prepare enough contiguous memory space for (v)dma ?

 

*1)

If you found cpu performance issue, it might be memory issue...

 

Best regards,

0 Kudos
Highlighted
Moderator
Moderator
574 Views
Registered: ‎11-09-2015

HI roland.ahearn@elbitsystems-us.com 

Do you have any update on this topic? Did @watari or my suggestion helped?

Thanks


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Highlighted
556 Views
Registered: ‎08-20-2019

Thank you for your replies.  We are still working on a solution to this and will reply to this post when we have an update.

Highlighted
Moderator
Moderator
441 Views
Registered: ‎11-09-2015

HI roland.ahearn@elbitsystems-us.com 

Just checking if you were able to make any progress on this?


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Highlighted
391 Views
Registered: ‎08-20-2019

We have tabled this issue and until next year.  I will keep the post updated to our progress.