[Ffmpeg-devel] svn 6835 crash in mpeg12.c

Aaron Williams aaronw
Sun Oct 29 19:43:33 CET 2006


Hi

Aaron Williams wrote:
> When trying to transcode a mpeg 2 file to h.264 I am immediately getting
> a crash. Yesterday's build did  not have this problem.
>
>
> I'm having trouble debugging this, probably due to the heavy compiler
> optimization.
>
> -Aaron
>
> run -pass 1 -i Battlestar\ Galactica\ -\ Exodus.mpg -vcodec h264 -acodec
> ac3 -ab 128 -ac 2 -b 1200k -maxrate 2000k -croptop 60 -cropbottom 60
> -cropleft 16 -s 704x360 -y -deinterlace -aspect 16:9 
> Battlestar_Galactica_-_Exodus.avi
>
> backtrace:
> #0  mpeg_decode_mb (s=0xabed20, block=<value optimized out>) at
> mpeg12.c:1916
> #1  0x000000000055a2ff in mpeg_decode_slice (s1=0xabed20, mb_y=<value
> optimized out>, buf=0x7fff8bc06760,
>     buf_size=<value optimized out>) at mpeg12.c:2591
> #2  0x000000000055aee4 in mpeg_decode_frame (avctx=0xabd310,
> data=0x7fff8bc06890,
>     data_size=0x7fff8bc06ccc, buf=0xb3d040 "", buf_size=52400) at
> mpeg12.c:3186
> #3  0x0000000000473a83 in avcodec_decode_video (avctx=0xabd310,
> picture=0x16,
>     got_picture_ptr=0x7fff8bc06ccc, buf=0x0, buf_size=22) at utils.c:901
> #4  0x0000000000426454 in av_find_stream_info (ic=0xab4070) at utils.c:1724
> #5  0x0000000000419657 in opt_input_file (filename=0x7fff8bc07f40
> "Battlestar Galactica - Exodus.mpg")
>     at ffmpeg.c:2616
> #6  0x00000000004214bc in parse_options (argc=30, argv=0x7fff8bc07628,
> options=0x81b5e0) at cmdutils.c:101
> #7  0x000000000041f360 in main (argc=30, argv=0x7fff8bc07628) at
> ffmpeg.c:3958
>
> mpeg_decode_mb (s=0xabed20, block=<value optimized out>) at mpeg12.c:1916
> 1916        block[0] = dc << (3 - s->intra_dc_precision);
> (gdb) p s
> $1 = (MpegEncContext *) 0xabed20
> (gdb) p block
> $2 = <value optimized out>
> (gdb) p dc
> No symbol "dc" in current context.
> (gdb) p s->intra_dc_precision
> $3 = 0
> (gdb) p s->block
> $5 = (DCTELEM (*)[64]) 0xb1aaf0
> (gdb) p s->block[0]
> $6 = {0 <repeats 64 times>}
>
> (gdb) p s->pblocks
> $7 = {0x0, 0xb1a570, 0xb1a5f0, 0xb1a670, 0xb1a6f0, 0xb1a770, 0xb1a7f0,
> 0xb1a870, 0xb1a8f0, 0xb1a970,
>   0xb1a9f0, 0xb1aa70}
>
> _______________________________________________
>   
If I compile mpeg12.c with -O2 instead of -O3 then it seems to work
fine.  I am compiling with GCC 4.1.0 (SUSE Linux) for an Athlon64
(-farch=athlon64). 

FFmpeg version SVN-r6280, Copyright (c) 2000-2006 Fabrice Bellard, et al.
  configuration:  --enable-libogg --enable-vorbis --enable-faad
--enable-faac --enable-xvid --enable-x264 --enable-a52 --enable-dts
--enable-dc1394 --enable-gpl --enable-mp3lame --enable-swscaler
--enable-pp --enable-amr_wb --enable-amr_nb --enable-amr_if2
--cpu=athlon64 --extra-cflags=-march=athlon64 -g
  libavutil version: 49.0.2
  libavcodec version: 51.21.0
  libavformat version: 50.6.0
  built on Oct 25 2006 13:48:02, gcc: 4.1.0 (SUSE Linux)
Segmentation fault





More information about the ffmpeg-devel mailing list