[FFmpeg-devel] H.264 Regressions for x86_32/gcc 2.95.3

Mike Melanson mike
Fri Feb 8 07:31:00 CET 2008


Loren Merritt wrote:
> Doesn't crash for me (but I don't have gcc 2.95), so I have to ask for all 
> the normal bugreport details.
> Also, do your cpu and assembler support ssse3? If not, it might be one of 
> the previous few commits that broke, and you just weren't using that code.

For every checkin (though they sometimes get stacked), the code is built 
for a variety of different gcc versions and the exact same tests are 
run. The database demonstrates that the tests worked until that commit.

The testing CPU supports SSSE3. If it did not and it tried to run a bad 
instruction, the program would have been killed for cause of illegal 
instruction, not segfault.

If the assembler did not support the instructions, I tend to think the 
program would not build at all.

> If I had to guess, it might be the notorious non-support of aligned 
> variables.

Could be:

Program received signal SIGSEGV, Segmentation fault.
0x0810ddc4 in put_h264_qpel16_mc23_ssse3 (dst=0x8299fc5 "\203?\020\203? ?",
     src=0x8653210 '\200' <repeats 64 times>, 
"\"\213???????????????????????????????\214|xuutsqkif`XPH>71./136;?DHLO^rwz~\203\215\215\215\215\205\177|zzzzz}}}}{|vswqieeeefoxtt\200\201\205\207\210\203|y\177~~\177\203\202\202\202\203\202\204z__][", 
'Z' <repeats 12 times>..., stride=140782355)
     at /home/melanson/ffmpeg/ffmpeg-main/libavcodec/i386/h264dsp_mmx.c:1894
1894    QPEL_H264_HV2_XMM(put_,       PUT_OP, ssse3)
(gdb) bt
#0  0x0810ddc4 in put_h264_qpel16_mc23_ssse3 (
     dst=0x8299fc5 "\203?\020\203? ?",
     src=0x8653210 '\200' <repeats 64 times>, 
"\"\213???????????????????????????????\214|xuutsqkif`XPH>71./136;?DHLO^rwz~\203\215\215\215\215\205\177|zzzzz}}}}{|vswqieeeefoxtt\200\201\205\207\210\203|y\177~~\177\203\202\202\202\203\202\204z__][", 
'Z' <repeats 12 times>..., stride=140782355)
     at /home/melanson/ffmpeg/ffmpeg-main/libavcodec/i386/h264dsp_mmx.c:1894


Everything after that in the backtrace is unknown. The dst argument here 
is shown to be 0x8299fc5. Is that cause for concern?

I missed the whole alignment debate, apparently (though I see the 
alignment message on any crash). I am guessing that certain gcc versions 
< 4.2 do not honor alignment directives? Can we just use the workaround 
of slightly over-allocating the buffer and aligning the data manually? 
Or is that frowned upon because we might allocate up to 15 bytes more 
than we need for operating?

-- 
	-Mike Melanson




More information about the ffmpeg-devel mailing list