Bug 79698 - vpp timing issue on hsw
Summary: vpp timing issue on hsw
Status: RESOLVED FIXED
Alias: None
Product: libva
Classification: Unclassified
Component: intel (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: haihao
QA Contact: Sean V Kelley
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-06-05 18:49 UTC by Rainer Hochecker
Modified: 2015-11-23 17:38 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Rainer Hochecker 2014-06-05 18:49:56 UTC
I am trying to get vpp working for XBMC. You probably know that this is working on SND and IVB but madi/maci make problems on hsw. Here are some new observations.

If I set a breakpoint before I configure the vpp context, wait for 2 sec, then continue it works. Without the breakpoint it fails. The video looks jumpy, 2 frames forward, one backward and so on.

I ran vpp on a 2nd thread. Not sure if this of any relevance to this issue.
Comment 1 Rainer Hochecker 2014-06-06 05:44:06 UTC
Sorry, actually it never works on hsw. The breakpoint made vaapi time out the player open sw codec.

I did some more tests:

- if I don't set the forward ref, ever 2nd picture is green
- if I set the ref, the pics look temporarily misordered.

How can we verify that the drivers picks the correct reference?
Comment 2 haihao 2014-06-06 06:04:30 UTC
As you mentioned in https://bugs.freedesktop.org/show_bug.cgi?id=79528, gst-vaapi + MADI works with MPEG-2 video on HSW, so do you mean XBMC + MADI doesn't work with MPEG-2 video on HSW ?
Comment 3 haihao 2014-06-06 06:11:30 UTC
Could you enable LIBVA_TRACE to dump VA parameters to a log file ?

e.g.

export LIBVA_TRACE=libva

then a log file named libva.xxx.xxx will be generated when you run xbmc with vaapi enabled.
Comment 4 Peter Frühberger 2014-06-06 06:15:44 UTC
The problem here has the following differences to the other bug:
1) xbmc is an openGL application
2) VPP is done in a different thread. So there is one thread for decoding and another one for doing the post processing.
Comment 5 Rainer Hochecker 2014-06-06 06:25:17 UTC
here is the trace file:
http://paste.ubuntu.com/7599764/
Comment 6 Rainer Hochecker 2014-06-07 09:31:41 UTC
after havin gdone some fixes to my code I created a new trace file:
http://paste.ubuntu.com/7606829/

Apart from the filter_flags it looks similar to the one I created with gst. 

sometimes the trace looks ugly, maybe a lock missing somewhere?

[54772.996222] 	element[28] = [54772.996222] --VASliceParameterBufferType
[54772.996225] 	element[29] = [54772.996225] --VASliceParameterBufferType
[54772.996149] [54772.996227] 	element[30] = [54772.996228] 	    x = 0
--VASliceParameterBufferType
[54772.996231] 	element[31] = [54772.996232] --VASliceParameterBufferType
[54772.996234] 	element[32] = [54772.996235] --VASliceParameterBufferType
[54772.996237] 	element[33] = [54772.996238] --VASliceParameterBufferType
[54772.996229] [54772.996239] 	    y = 0
[54772.996242] 	    width = 720
	element[34] = [54772.996245] --VASliceParameterBufferType
[54772.996250] 	element[35] = [54772.996250] --VASliceParameterBufferType
[54772.996255] 	---------------------------
[54772.996243] [54772.996257] 	    height = 576
	buffers[1] = 0x08000003
[54772.996259] 	  output_background_color = 0xff000000
[54772.996260] [54772.996260] 	  output_color_standard = 0
	  type = VASliceDataBufferType
[54772.996262] [54772.996262] 	  size = 17062
[54772.996263] 	  pipeline_flags = 0x00000000
	  num_elements = 1
[54772.996265] 	  filter_flags = 0x00000001
Comment 7 Rainer Hochecker 2014-09-09 08:02:16 UTC
This seems to be fixed with Gwenole's vpp fixes https://github.com/gbeauchesne/libva-intel-driver/tree/17.vpp.vebox
Comment 8 haihao 2015-11-23 16:41:12 UTC
Can you reproduce this issue with the latest driver? I remember all patches have been merged into master branch.
Comment 9 Rainer Hochecker 2015-11-23 16:56:45 UTC
fixed in latest driver
Comment 10 haihao 2015-11-23 17:38:16 UTC
Thanks for your confirmation.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.