<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - amdgpu hevc encoding problems: segment fault and contents of garbage"
href="https://bugs.freedesktop.org/show_bug.cgi?id=110673#c2">Comment # 2</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - amdgpu hevc encoding problems: segment fault and contents of garbage"
href="https://bugs.freedesktop.org/show_bug.cgi?id=110673">bug 110673</a>
from <span class="vcard"><a class="email" href="mailto:mfk530@gmail.com" title="zhoulei <mfk530@gmail.com>"> <span class="fn">zhoulei</span></a>
</span></b>
<pre>(In reply to Boyuan Zhang from <a href="show_bug.cgi?id=110673#c1">comment #1</a>)
<span class="quote">> Hi Zhoulei,
>
> Thanks for pointing out these 2 issues.
>
> I reproduced issue#1, and have a fix submitted for code review:
> <a href="https://lists.freedesktop.org/archives/mesa-dev/2019-May/219392.html">https://lists.freedesktop.org/archives/mesa-dev/2019-May/219392.html</a>
>
> Please give a try.
>
> And I will investigate issue#2.</span >
Hi Boyuan,
I have tried the patch in my R5 2400G(ArchLinux, mesa-19.0.4).
Segment fault is gone, but new issue is found.
reproduce:
No more segment fault when using ffmpeg to produce hevc stream.
ffmpeg -vaapi_device /dev/dri/renderD128 -i input.avi -vf
'format=nv12,hwupload' -c:v hevc_vaapi -bf 0 -g 7 output.mp4
But Some error messages is shown when decoding the encoded stream.
$ mpv output.mp4
Playing: output.mp4
(+) Video --vid=1 (*) (hevc 1920x1080 23.976fps)
(+) Audio --aid=1 (*) (aac 2ch 48000Hz)
Using hardware decoding (vaapi).
AO: [pulse] 48000Hz stereo 2ch float
VO: [vaapi] 1920x1088 vaapi[nv12]
AV: 00:00:00 / 00:00:04 (4%) A-V: 0.006 DS: 2.857/0
[ffmpeg/video] hevc: Could not find ref with POC 7
AV: 00:00:00 / 00:00:04 (11%) A-V: 0.004 DS: 2.643/0
[ffmpeg/video] hevc: Could not find ref with POC 14
AV: 00:00:00 / 00:00:04 (12%) A-V: 0.004 DS: 2.667/0
[ffmpeg/video] hevc: Could not find ref with POC -1
AV: 00:00:00 / 00:00:04 (17%) A-V: 0.004 DS: 2.619/0
[ffmpeg/video] hevc: Could not find ref with POC 5
AV: 00:00:01 / 00:00:04 (24%) A-V: 0.005 DS: 2.571/0
[ffmpeg/video] hevc: Could not find ref with POC 12
AV: 00:00:01 / 00:00:04 (26%) A-V: 0.005 DS: 2.581/0
[ffmpeg/video] hevc: Could not find ref with POC -1
AV: 00:00:01 / 00:00:04 (30%) A-V: 0.005 DS: 2.571/0
[ffmpeg/video] hevc: Could not find ref with POC 3
AV: 00:00:01 / 00:00:04 (37%) A-V: 0.006 DS: 2.548/0
[ffmpeg/video] hevc: Could not find ref with POC 10
AV: 00:00:01 / 00:00:04 (41%) A-V: 0.006 DS: 2.532/0
[ffmpeg/video] hevc: Could not find ref with POC -1
AV: 00:00:01 / 00:00:04 (43%) A-V: 0.006 DS: 2.531/0
[ffmpeg/video] hevc: Could not find ref with POC 1
AV: 00:00:02 / 00:00:04 (50%) A-V: 0.005 DS: 2.536/0
[ffmpeg/video] hevc: Could not find ref with POC 8
AV: 00:00:02 / 00:00:04 (56%) A-V: 0.005 DS: 2.524/0
[ffmpeg/video] hevc: Duplicate POC in a sequence: 0.
[ffmpeg/video] hevc: Error parsing NAL unit #1.
Error while decoding frame!
AV: 00:00:02 / 00:00:04 (62%) A-V: 0.005 DS: 2.565/0
[ffmpeg/video] hevc: Could not find ref with POC 6
AV: 00:00:03 / 00:00:04 (69%) A-V: 0.005 DS: 2.566/0
[ffmpeg/video] hevc: Could not find ref with POC 13
AV: 00:00:03 / 00:00:04 (71%) A-V: 0.004 DS: 2.564/0
[ffmpeg/video] hevc: Could not find ref with POC -1
AV: 00:00:03 / 00:00:04 (75%) A-V: 0.004 DS: 2.554/0
[ffmpeg/video] hevc: Could not find ref with POC 4
AV: 00:00:03 / 00:00:04 (82%) A-V: 0.004 DS: 2.556/0
[ffmpeg/video] hevc: Could not find ref with POC 11
AV: 00:00:03 / 00:00:04 (86%) A-V: 0.004 DS: 2.553/0
[ffmpeg/video] hevc: Could not find ref with POC -1
AV: 00:00:04 / 00:00:04 (88%) A-V: 0.003 DS: 2.546/0
[ffmpeg/video] hevc: Could not find ref with POC 2
AV: 00:00:04 / 00:00:04 (93%) A-V: 0.000 DS: 2.545/0</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
<li>You are the QA Contact for the bug.</li>
</ul>
</body>
</html>