|
From: Johannes R. <Joh...@un...> - 2006-09-10 10:38:29
|
Hi, I have a problem with valgrind. When I try to memcheck xvid_encraw (a commandline mpeg4 video encoder from the XviD project (http://www.xvid.org), valgrind crashes. The sources are available from the website. I used a recent (september 10.) cvs checkout. I made libxvidcore with the makefile in xvidcore/build/generic/ and then made xvid encraw in the xvidcore/examples folder. It then crashes valgrind with every sample I tried. Disabling cpu specific optimization (-noasm) prevents from crashing. I am on Xubuntu Dapper Drake. There is a file called libc-2.3.6.so in my /lib folder, so I assume I use libc 2.3.6. The verbose output of valgerind is attached. If there is something else you need to know, let it know me. Thank you for this great tool, it is very useful. Regards Johannes jreinhardt@jreinhardt-desktop:~/sources/xvid/xvidcore/examples$ uname -a Linux jreinhardt-desktop 2.6.15-26-386 #1 PREEMPT Thu Aug 3 02:52:00 UTC 2006 i686 GNU/Linux jreinhardt@jreinhardt-desktop:~/sources/xvid/xvidcore/examples$ valgrind -v ./xvid_encraw -i ~/videos/test/katze.yuv -w 320 -h 240 -type 0 ==5718== Memcheck, a memory error detector. ==5718== Copyright (C) 2002-2005, and GNU GPL'd, by Julian Seward et al. ==5718== Using LibVEX rev 1471, a library for dynamic binary translation. ==5718== Copyright (C) 2004-2005, and GNU GPL'd, by OpenWorks LLP. ==5718== Using valgrind-3.1.0-Debian, a dynamic binary instrumentation framework. ==5718== Copyright (C) 2000-2005, and GNU GPL'd, by Julian Seward et al. ==5718== --5718-- Command line --5718-- ./xvid_encraw --5718-- -i --5718-- /home/jreinhardt/videos/test/katze.yuv --5718-- -w --5718-- 320 --5718-- -h --5718-- 240 --5718-- -type --5718-- 0 --5718-- Startup, with flags: --5718-- -v --5718-- Contents of /proc/version: --5718-- Linux version 2.6.15-26-386 (buildd@terranova) (gcc version 4.0.3 (Ubuntu 4.0.3-1ubuntu5)) #1 PREEMPT Thu Aug 3 02:52:00 UTC 2006 --5718-- Arch and subarch: X86, x86-sse2 --5718-- Valgrind library directory: /usr/lib/valgrind --5718-- Reading syms from /lib/ld-2.3.6.so (0x4000000) --5718-- Reading debug info from /lib/ld-2.3.6.so... --5718-- ... CRC mismatch (computed F305999E wanted 041122DD) --5718-- object doesn't have a symbol table --5718-- Reading syms from /home/jreinhardt/sources/xvid/xvidcore/examples/xvid_encraw (0x8048000) --5718-- Reading syms from /usr/lib/valgrind/x86-linux/memcheck (0xA000000) --5718-- object doesn't have a dynamic symbol table --5718-- Reading suppressions file: /usr/lib/valgrind/default.supp --5718-- Reading syms from /usr/lib/valgrind/x86-linux/vgpreload_core.so (0x4019000) --5718-- Reading syms from /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so (0x401B000) --5718-- Reading syms from /lib/tls/i686/cmov/libc-2.3.6.so (0x4031000) --5718-- Reading debug info from /lib/tls/i686/cmov/libc-2.3.6.so... --5718-- ... CRC mismatch (computed 2A207A12 wanted C99D524A) --5718-- object doesn't have a symbol table --5718-- Reading syms from /lib/tls/i686/cmov/libm-2.3.6.so (0x4160000) --5718-- Reading debug info from /lib/tls/i686/cmov/libm-2.3.6.so... --5718-- ... CRC mismatch (computed 2525B926 wanted 9953A5EA) --5718-- object doesn't have a symbol table --5718-- Reading syms from /lib/tls/i686/cmov/libpthread-2.3.6.so (0x4182000) --5718-- Reading debug info from /lib/tls/i686/cmov/libpthread-2.3.6.so... --5718-- ... CRC mismatch (computed A7DB34C2 wanted A58FB47C) --5718-- REDIR: 0x409C490 (memset) redirected to 0x401E209 (memset) --5718-- REDIR: 0x409C9C0 (memcpy) redirected to 0x401E2CD (memcpy) --5718-- REDIR: 0x409B640 (rindex) redirected to 0x401DD72 (rindex) xvid_encraw - raw mpeg4 bitstream encoder written by Christoph Lampert 2002-2003 --5718-- REDIR: 0x4096390 (malloc) redirected to 0x401C3A0 (malloc) --5718-- REDIR: 0x409B270 (strlen) redirected to 0x401DEE5 (strlen) xvidcore build version: xvid-1.2.0-dev Bitstream version: 1.2.-127 Detected CPU flags: ASM MMX MMXEXT SSE SSE2 TSC Detected 0 cpus, using 0 threads. --5718-- REDIR: 0x40942C0 (free) redirected to 0x401CF51 (free) 0: key=2, time= 626, len= 20387 | type=I, quant= 4, len= 20387 vex: the `impossible' happened: LibVEX_N_SPILL_BYTES is too low. Increase and recompile. vex storage: T total 135366736 bytes allocated valgrind: the 'impossible' happened: LibVEX called failure_exit(). ==5718== at 0xA010AB3: report_and_quit (m_libcassert.c:122) ==5718== by 0xA010D40: panic (m_libcassert.c:195) ==5718== by 0xA010D7D: vgPlain_core_panic_at (m_libcassert.c:200) ==5718== by 0xA010DAE: vgPlain_core_panic (m_libcassert.c:205) ==5718== by 0xA02355B: failure_exit (m_translate.c:345) ==5718== by 0xA0702F5: vpanic (vex_util.c:225) ==5718== by 0xA098D99: doRegisterAllocation (reg_alloc2.c:737) ==5718== by 0xA06F2E6: LibVEX_Translate (vex_main.c:563) ==5718== by 0xA023AEC: vgPlain_translate (m_translate.c:579) ==5718== by 0xA035771: handle_tt_miss (scheduler.c:596) ==5718== by 0xA035BFD: vgPlain_scheduler (scheduler.c:717) ==5718== by 0xA04A183: thread_wrapper (syswrap-linux.c:86) ==5718== by 0xA04A2B0: run_a_thread_NORETURN (syswrap-linux.c:119) sched status: running_tid=1 Thread 1: status = VgTs_Runnable ==5718== at 0x80A1680: sad16_sse2 (in /home/jreinhardt/sources/xvid/xvidcore/examples/xvid_encraw) ==5718== by 0x0: ??? Note: see also the FAQ.txt in the source distribution. It contains workarounds to several common problems. If that doesn't help, please report this bug to: www.valgrind.org In the bug report, send all the above text, the valgrind version, and what Linux distro you are using. Thanks. |
|
From: Julian S. <js...@ac...> - 2006-09-10 10:54:54
|
> vex: the `impossible' happened: > LibVEX_N_SPILL_BYTES is too low. Increase and recompile. A trivially fixed bug; the register allocator ran out of spill slots. I suggest you try 3.2.0; LibVEX_N_SPILL_BYTES (2048) is twice what it is in 3.1.0 (1024), and so your program may well work fine with 3.2.0. If not, get back to me and I'll increase it still further. J |