PDA

View Full Version : Trying to play video crashes out


pancus
2007-10-12, 06:33
First off let me say I've been quietly playing with the SVN builds and I'm floored at how fast this was developed. Good job! :)

I have been building this in Gentoo (I know it's not Ubuntu/officially supported) and everything has been working fine. Recently, in the last two weeks or so, trying to play any videos would make xbmc crash. The only error it would spit out is "Floating point exception". Everything else seems to work fine.

My system is a p4 2.8g, nvidia 6600GT and 1.5g of ram so it has enough juice. Any more info/tests you want me to run just ask.

On a side note I have to manually add -llzo2 as I don't think it's being detected, I used to have to add -lasound as well but that was fixed.

pancus
2007-10-16, 07:23
I compiled another version from the SVN and here's the strace -f

[pid 22677] <... gettimeofday resumed> {1192511327, 210043}, NULL) = 0
[pid 22678] <... read resumed> 0xb11d5d64, 32) = -1 EAGAIN (Resource temporarily unavailable)
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] poll( <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1) = 0
[pid 22677] gettimeofday({1192511327, 210575}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1) = 0
[pid 22677] gettimeofday({1192511327, 210856}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c6bba0, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1) = 0
[pid 22677] gettimeofday({1192511327, 211710}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1) = 0
[pid 22677] gettimeofday({1192511327, 212143}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c6bba0, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1) = 0
[pid 22677] gettimeofday({1192511327, 212435}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1) = 0
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1 <unfinished ...>
[pid 22662] <... nanosleep resumed> {0, 100000000}) = 0
[pid 22678] <... poll resumed> [{fd=7, events=POLLIN, revents=POLLIN}], 1, -1) = 1
[pid 22677] <... futex resumed> ) = 0
[pid 22662] futex(0x8bfd7b8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] read(7, <unfinished ...>
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22662] <... futex resumed> ) = 0
[pid 22678] <... read resumed> "\1\0\255\0\0\0\0\0\0\0X\2\1\1\36\10\0\36\217\277\3 0\36"..., 32) = 32
[pid 22677] <... futex resumed> ) = 0
[pid 22662] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] write(7, "k\5\3\0\0\0X\2\1\1\2\0_\0\2\0\7\0\0\1+\0\1\0", 24 <unfinished ...>
[pid 22677] futex(0x8b978d0, FUTEX_WAIT, 2, NULL <unfinished ...>
[pid 22662] <... futex resumed> ) = 0
[pid 22678] <... write resumed> ) = 24
[pid 22662] futex(0x8b978d0, FUTEX_WAKE, 1 <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] read(7, <unfinished ...>
[pid 22662] <... futex resumed> ) = 1
[pid 22677] futex(0x8b978d0, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... read resumed> "\1\2\260\0\0\0\0\0\7\0`\0\0\36\217\277\30\36\217\2 77\320"..., 32) = 32
[pid 22662] futex(0x8955c88, FUTEX_WAKE, 1 <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] write(8, "<\3\2\0\0\0 \1+\0\1\0", 12 <unfinished ...>
[pid 22662] <... futex resumed> ) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... write resumed> ) = 12
[pid 22662] futex(0x8b64648, FUTEX_WAKE, 1 <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] read(8, <unfinished ...>
[pid 22662] <... futex resumed> ) = 0
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... read resumed> "\1\2\22\0\0\0\0\0\7\0`\0\0\36\217\277\30\36\217\27 7\320"..., 32) = 32
[pid 22662] gettimeofday( <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] shutdown(8, 2 /* send and receive */ <unfinished ...>
[pid 22662] <... gettimeofday resumed> {1192511327, 240422}, NULL) = 0
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... shutdown resumed> ) = 0
[pid 22662] nanosleep({0, 0}, <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] close(8 <unfinished ...>
[pid 22662] <... nanosleep resumed> {0, 0}) = 0
[pid 22677] gettimeofday( <unfinished ...>
[pid 22678] <... close resumed> ) = 0
[pid 22662] gettimeofday( <unfinished ...>
[pid 22677] <... gettimeofday resumed> {1192511327, 240677}, NULL) = 0
[pid 22678] write(7, "<\5\2\0\0\0\0\1+\1\1\0", 12 <unfinished ...>
[pid 22662] <... gettimeofday resumed> {1192511327, 240721}, NULL) = 0
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... write resumed> ) = 12
[pid 22662] futex(0x8955d70, FUTEX_WAIT, 0, NULL <unfinished ...>
[pid 22677] <... futex resumed> ) = 0
[pid 22678] read(7, <unfinished ...>
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... read resumed> "\1\2\262\0\0\0\0\0\7\0`\0\0\36\217\277\30\36\217\2 77\320"..., 32) = 32
[pid 22677] <... futex resumed> ) = 0
[pid 22678] shutdown(7, 2 /* send and receive */ <unfinished ...>
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... shutdown resumed> ) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] close(7 <unfinished ...>
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... close resumed> ) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] munmap(0xb6ba7000, 23772 <unfinished ...>
[pid 22677] gettimeofday( <unfinished ...>
[pid 22678] <... munmap resumed> ) = 0
[pid 22677] <... gettimeofday resumed> {1192511327, 241727}, NULL) = 0
[pid 22678] rt_sigaction(SIGSEGV, NULL, <unfinished ...>
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> {0xb7b486d3, [], 0}, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] rt_sigaction(SIGSEGV, {SIG_DFL}, <unfinished ...>
[pid 22677] futex(0x8c6bba0, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> NULL, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] rt_sigaction(SIGBUS, NULL, <unfinished ...>
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> {0xb7b486d3, [], 0}, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] rt_sigaction(SIGBUS, {SIG_DFL}, <unfinished ...>
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> NULL, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] rt_sigaction(SIGFPE, NULL, <unfinished ...>
[pid 22677] gettimeofday( <unfinished ...>
[pid 22678] <... rt_sigaction resumed> {SIG_DFL}, 8) = 0
[pid 22677] <... gettimeofday resumed> {1192511327, 242131}, NULL) = 0
[pid 22678] rt_sigaction(SIGQUIT, NULL, <unfinished ...>
[pid 22677] futex(0x8c4f6b8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> {0xb7b486d3, [], 0}, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] rt_sigaction(SIGQUIT, {SIG_DFL}, <unfinished ...>
[pid 22677] futex(0x8aa0c40, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... rt_sigaction resumed> NULL, 8) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] tgkill(22662, 22678, SIGFPE <unfinished ...>
[pid 22677] futex(0x8c9aaf8, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... tgkill resumed> ) = 0
[pid 22677] <... futex resumed> ) = 0
[pid 22678] sigreturn( <unfinished ...>
[pid 22677] futex(0x8c60688, FUTEX_WAKE, 1 <unfinished ...>
[pid 22678] <... sigreturn resumed> ) = ? (mask now [HUP INT QUIT PIPE ALRM TERM CHLD VTALRM PROF WINCH])
[pid 22677] <... futex resumed> ) = 0
[pid 22678] --- SIGFPE (Floating point exception) @ 0 (0) ---
Process 22678 detached
[pid 22672] <... futex resumed> ) = ? ERESTARTSYS (To be restarted)
[pid 22663] <... futex resumed> ) = ? ERESTART_RESTARTBLOCK (To be restarted)
[pid 22662] <... futex resumed> ) = ? ERESTARTSYS (To be restarted)
[pid 22672] +++ killed by SIGFPE +++
Process 22672 detached
[pid 22663] +++ killed by SIGFPE +++
Process 22663 detached
[pid 22677] +++ killed by SIGFPE +++
Process 22677 detached
[pid 22679] +++ killed by SIGFPE +++
Process 22679 detached
+++ killed by SIGFPE +++
Process 22662 detached

d4rk
2007-10-16, 16:25
Did you do a make clean before you recompiled? If you did and it still crashes, please paste (http://rafb.net/paste/) your xbmc.log, console log and the gdb backtrace of the crash.

Edit: Also make sure that the latest *.so files under system have been copied over.

pancus
2007-10-17, 21:16
For good measure I blew away everything and redownloaded the svn.

http://www.pagpaintball.com/tempfolder/xbmcdebug.bz2
http://www.pagpaintball.com/tempfolder/xbmc.log.bz2

I started xbmc, went straight to video and tried to play an avi. I'll get a backtrace on here when I get a chance.

Incidentally, I saw in the this in the svn log
fixed: correctly check for liblzo and not liblzo2 to prevent certain linking errors if only liblzo2 is found.
I only have lzo2 installed and it dies when compiling, so I edit the makefile and change -llzo to -llzo2, rerun make and it finishes fine.

XyLo
2007-10-19, 16:01
I have the same problem on Gentoo. I can compile XBMC without any modifications or problems when I _only_ have lzo 1.08 installed. If lzo 2.02 is installed the compilation fails with a reference error, without lzo 1.08 it already fails at configure. If I want to compile XBMC with 2.02 I have to use the -llzo2 trick mentioned by pancus.

I did a backtrace of XBMC compiled with 1.08 (without 2.02 installed), I hope I did it right:
http://rafb.net/p/Xx8Trn16.html

pancus
2007-10-19, 16:50
I just threw one up too.

http://rafb.net/p/bD7iPL45.html

Hope this helps.

XyLo
2007-10-19, 19:04
After taking a second look at the traceback I started fiddling around with the use-flags of libsdl. I added 'oss' and re-emerged libsdl, started XBMC and it gave me a green screen instead of the occasional segmentation fault. Doing a search for green screens directed me to this topic:
http://xbmc.org/forum/showthread.php?t=28863&highlight=green

The post by HendrikDK tells about the GeForce FX and the problems with it not being compatible. I happen to have a GeForce FX 5650 Go in the laptop I'm testing this on, so I tried the suggested 10133 revision. This revision gives me the usual segmentation fault instead of the green screen. I'm going to try if I got more luck with one of my desktops.

pancus
2007-10-25, 09:18
Unfortunately I still have this problem. I tried a few things to no avail, any advice on tracking this one down?

hrak
2007-10-30, 18:12
I have the same "Floating Point Exception" problem on Gentoo as the topicstarter. libsdl is already compiled with USE flag oss, so that doesn't fly for me. The crash happens in libasound, which probably expains why switching to oss fixed the problem for XyLo.

Piece of log and a backtrace can be found here: http://home.react.nl/~hans/xbmc/asound_crash.txt

hrak
2007-10-30, 18:55
Quick follow-up: For some strange reason compiling media-libs/alsa-lib with USE flag 'debug' solves the floating point exception. I have a working XBMC now :)

I'll look for an explanation later today!

pancus
2007-10-31, 22:26
I can confirm this worked for me as well. Interesting.

danish
2008-01-04, 23:17
Adding the debug flag to alsa-lib also worked for me.

doctorgod
2008-01-06, 13:53
I was having the same problem. Although I haven't taken the time to trace out exactly what's going on (from my limited investigation, it appears that the "frame_bits" member of "m_pPlayHandle" is not being initialized properly), I was able to fix it by making a change to XBMC/cores/dvdplayer/ALSADirectSound.cpp.

Change the following line (currently line 177) m_BufferSize = snd_pcm_bytes_to_frames(m_pPlayHandle,m_dwPacketSi ze * 10); // buffer big enough - but not too big... to read as it did before revision 10060: m_BufferSize = m_dwPacketSize * 10; // buffer big enough - but not too big...

I've seen this on two other Gentoo machines, so perhaps this is a bug in their alsa-lib. Both machines use the "Intel HD Audio" driver built into the kernel (snd-hda-intel). I'd interested to know what audio hardware other people seeing this problem have.

bejean
2008-06-02, 00:00
I also had this problem and emerging alsa-libs with the "debug" use flag also fixed it. I am also using the kernel ALSA driver for my Intel HD audio. I'm going to try doctorgod's change to see if that allows me to use alsa-libs without the debug flag. However, I don't know enough about the code to understand what doctorgod's change does yet.

bejean
2008-06-02, 00:51
doctorgod's change didn't prevent the crashes on video playback. Only emerging alsa-lib with the debug use flag seemed to fix it, but I'm still getting some choppy sound issues.

TobiasTheCommie
2008-07-24, 02:27
I have this exact same problem, thanks for the solution, have been killing me..

Here is a backtrace for the developers..

http://rafb.net/p/BFsi4D77.html