From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon@freedesktop.org Subject: [Bug 97075] VCE encoding slow when GPU is not stressed (HD 7970M) Date: Mon, 25 Jul 2016 14:27:51 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0356981583==" Return-path: Received: from culpepper.freedesktop.org (culpepper.freedesktop.org [IPv6:2610:10:20:722:a800:ff:fe98:4b55]) by gabe.freedesktop.org (Postfix) with ESMTP id 01ED46E0AC for ; Mon, 25 Jul 2016 14:27:51 +0000 (UTC) List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============0356981583== Content-Type: multipart/alternative; boundary="14694568700.FaED0E766.11396"; charset="UTF-8" --14694568700.FaED0E766.11396 Date: Mon, 25 Jul 2016 14:27:50 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated https://bugs.freedesktop.org/show_bug.cgi?id=3D97075 Bug ID: 97075 Summary: VCE encoding slow when GPU is not stressed (HD 7970M) Product: DRI Version: unspecified Hardware: Other OS: All Status: NEW Severity: normal Priority: medium Component: DRM/Radeon Assignee: dri-devel@lists.freedesktop.org Reporter: haagch@frickel.club This is on an intel + radeon laptop, so I need to run encoding with gstream= er with DRI_PRIME=3D1. Here is an example video: http://www.sample-videos.com/video/mp4/720/big_buck_bunny_720p_1mb.mp4 DRI_PRIME is doing a good job of waking up the GPU from runpm when needed f= or encoding via VAAPI and OMX, but for comparison I'll run glxgears both times. I'm encoding the mentioned example video with VAAPI with this exact command: $ time DRI_PRIME=3D1 LIBVA_DRIVER_NAME=3Dradeonsi gst-launch-1.0 -e filesrc location=3Dbig_buck_bunny_720p_1mb.mp4 ! qtdemux ! h264parse ! avdec_h264 != queue ! videoconvert ! queue ! video/x-raw,format=3DNV12 ! vaapih264enc ! h264par= se ! matroskamux ! filesink location=3Doutput.mkv For low GPU stress I run the gst pipeline while glxgears with vsync is runn= ing: $ DRI_PRIME=3D1 glxgears Result: 0.75s user 0.33s system 2% cpu 52.779 total For higher GPU stress I run the gst pipeline while glxgears without vsync is running: $ DRI_PRIME=3D1 vblank_mode=3D0 glxgears Result: 0.99s user 0.28s system 43% cpu 2.928 total I also tried a very similar pipeline with OMX: $ time DRI_PRIME=3D1 gst-launch-1.0 -e filesrc location=3Dbig_buck_bunny_720p_1mb.mp4 ! qtdemux ! h264parse ! avdec_h264 != queue ! videoconvert ! queue ! video/x-raw,format=3DNV12 ! omxh264enc ! h264parse= ! matroskamux ! filesink location=3Doutput.mkv Low GPU stress: 0.96s user 0.24s system 19% cpu 6.298 total High GPU stress: 1.10s user 0.24s system 141% cpu 0.949 total Overall OMX encoding does a lot better, but it's still a large difference a= nd still below "real time" for the 5 second video. --=20 You are receiving this mail because: You are the assignee for the bug.= --14694568700.FaED0E766.11396 Date: Mon, 25 Jul 2016 14:27:50 +0000 MIME-Version: 1.0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated
Bug ID 97075
Summary VCE encoding slow when GPU is not stressed (HD 7970M)
Product DRI
Version unspecified
Hardware Other
OS All
Status NEW
Severity normal
Priority medium
Component DRM/Radeon
Assignee dri-devel@lists.freedesktop.org
Reporter haagch@frickel.club

This is on an intel + radeon laptop, so I need to run encoding=
 with gstreamer
with DRI_PRIME=3D1.

Here is an example video:
http://www.sample-videos.com/video/mp4/720/big_buck_bunny_720p_1mb.=
mp4

DRI_PRIME is doing a good job of waking up the GPU from runpm when needed f=
or
encoding via VAAPI and OMX, but for comparison I'll run glxgears both times.

I'm encoding the mentioned example video with VAAPI with this exact command:
$ time DRI_PRIME=3D1 LIBVA_DRIVER_NAME=3Dradeonsi gst-launch-1.0 -e filesrc
location=3Dbig_buck_bunny_720p_1mb.mp4 ! qtdemux ! h264parse ! avdec_h264 !=
 queue
! videoconvert ! queue ! video/x-raw,format=3DNV12 ! vaapih264enc ! h264par=
se !
matroskamux ! filesink location=3Doutput.mkv

For low GPU stress I run the gst pipeline while glxgears with vsync is runn=
ing:
$ DRI_PRIME=3D1 glxgears
Result: 0.75s user 0.33s system 2% cpu 52.779 total

For higher GPU stress I run the gst pipeline while glxgears without vsync is
running:
$ DRI_PRIME=3D1 vblank_mode=3D0 glxgears
Result: 0.99s user 0.28s system 43% cpu 2.928 total



I also tried a very similar pipeline with OMX:
$ time DRI_PRIME=3D1 gst-launch-1.0 -e filesrc
location=3Dbig_buck_bunny_720p_1mb.mp4 ! qtdemux ! h264parse ! avdec_h264 !=
 queue
! videoconvert ! queue ! video/x-raw,format=3DNV12 ! omxh264enc ! h264parse=
 !
matroskamux ! filesink location=3Doutput.mkv

Low GPU stress: 0.96s user 0.24s system 19% cpu 6.298 total
High GPU stress: 1.10s user 0.24s system 141% cpu 0.949 total

Overall OMX encoding does a lot better, but it's still a large difference a=
nd
still below "real time" for the 5 second video.


You are receiving this mail because:
  • You are the assignee for the bug.
= --14694568700.FaED0E766.11396-- --===============0356981583== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVs IG1haWxpbmcgbGlzdApkcmktZGV2ZWxAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlz dHMuZnJlZWRlc2t0b3Aub3JnL21haWxtYW4vbGlzdGluZm8vZHJpLWRldmVsCg== --===============0356981583==--