Thread: [Libxine-java-devel] VM Crash on ubuntu
Status: Beta
Brought to you by:
freckle
From: Kristian L. L. <wa...@pa...> - 2008-09-23 05:18:22
|
Hey I'm currently running kubuntu 8.04.1, manually installed jdk1.6.0_10 and developing in netbeans-6.1. When i try to run my program, the VM crashes aprox. 9/10 times when i try to bind the controller to the video canvas: engine.createController( video ); The vm dumps the following: # # An unexpected error has been detected by Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007feebe8aca6d, pid=32602, tid=1097247056 # # Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0-b15 mixed mode linux-amd64) # Problematic frame: # C [libxineJNI.so.0.0.0+0x1fa6d] xineJ_create_visual+0x35 # # An error report file with more information is saved as: # /home/walker/NetBeansProjects/TestVideo/hs_err_pid32602.log # # If you would like to submit a bug report, please visit: # http://java.sun.com/webapps/bugreport/crash.jsp # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # Java Result: 134 Any idea? Thanx walker |
From: Matthias R. <mri...@in...> - 2008-09-23 05:48:00
|
Hi Kristian that looks serious. I don't know what's failing. What CPU do you have? In the log it says something about 64-bit. So far I did not have a chance to test with 64-bit machines. Could you sent me the crash log (/hs_err_pid32602.log), maybe it tells us something. I have a standard Pentium 4 Ubuntu 8.04 for the linux development and a slightly older Java VM there: java version "1.6.0_06" Java(TM) SE Runtime Environment (build 1.6.0_06-b02) Java HotSpot(TM) Client VM (build 10.0-b22, mixed mode, sharing) Does the normal xine-ui (just xine on the command line) work fine on your system (just trying to check everything) matthias On Sep 23, 2008, at 7:18 AM, Kristian Lindemann Larsen wrote: > Hey > I'm currently running kubuntu 8.04.1, manually installed jdk1.6.0_10 > and > developing in netbeans-6.1. > When i try to run my program, the VM crashes aprox. 9/10 times when i > try to bind the controller to the video canvas: > > engine.createController( video ); > > The vm dumps the following: > > # > # An unexpected error has been detected by Java Runtime Environment: > # > # SIGSEGV (0xb) at pc=0x00007feebe8aca6d, pid=32602, tid=1097247056 > # > # Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0-b15 mixed mode > linux-amd64) > # Problematic frame: > # C [libxineJNI.so.0.0.0+0x1fa6d] xineJ_create_visual+0x35 > # > # An error report file with more information is saved as: > # /home/walker/NetBeansProjects/TestVideo/hs_err_pid32602.log > # > # If you would like to submit a bug report, please visit: > # http://java.sun.com/webapps/bugreport/crash.jsp > # The crash happened outside the Java Virtual Machine in native code. > # See problematic frame for where to report the bug. > # > Java Result: 134 |
From: Kristian L. L. <wa...@pa...> - 2008-09-23 14:55:14
|
Okay. My CPU is an "AMD Turion(tm) 64 X2 Mobile Technology TL-56", so yes, it's 64 bit (64-bit kubuntu). Here's a new crash that i made, with the test-player that comes with the build: # # An unexpected error has been detected by Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007f9423a9ec8d, pid=19716, tid=1090947408 # # Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0-b15 mixed mode linux-amd64) # Problematic frame: # C [libxineJNI.so.0.0.0+0x21c8d] xineJ_create_visual+0x35 # # An error report file with more information is saved as: # /home/walker/libxine-java-r375/hs_err_pid19716.log # # If you would like to submit a bug report, please visit: # http://java.sun.com/webapps/bugreport/crash.jsp # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # Aborted I've attached the /home/walker/libxine-java-r375/hs_err_pid19716.log file. When trying to configure (currently trying r375) i get the following error: ---------------------------- ./configure --prefix=/opt/jdk1.6.0_10 ... checking for jawt_md.h... yes Cannot find libjawt, please specify --with-jni-lib-flags. ---------------------------- I fix this by inserting the following line at line 22255 in configure: JNI_LIB="-L/opt/jdk1.6.0_10/jre/lib/amd64/" Then when trying to compile (make) i get the following error: ---------------------------- libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xineJ_1open': libxine_wrap.c:1096: warning: cast to pointer from integer of different size libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xineJ_1create_1visual': libxine_wrap.c:1116: warning: cast to pointer from integer of different size libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xineJ_1post_1init': libxine_wrap.c:1181: warning: cast to pointer from integer of different size libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xine_1trick_1mode': libxine_wrap.c:1533: warning: 'xine_trick_mode' is deprecated (declared at /usr/include/xine.h:261) libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xine_1vlog': libxine_wrap.c:3297: error: incompatible types in assignment make: *** [libxine_wrap.lo] Error 1 ---------------------------- i fix this by: - arg4 = *argp4; - xine_vlog(arg1,arg2,(char const *)arg3,arg4); + xine_vlog(arg1,arg2,(char const *)arg3,*argp4); which makes it compile. Is this dangerous, and could this have anything to do with the crash? Thanx walker Matthias Ringwald skrev: > Hi Kristian > > that looks serious. I don't know what's failing. What CPU do you have? > In the log it says something about 64-bit. So far I did not have a > chance to test with 64-bit machines. > Could you sent me the crash log (/hs_err_pid32602.log), maybe it tells > us something. I have a standard Pentium 4 Ubuntu 8.04 for the linux > development and a slightly older Java VM there: > > java version "1.6.0_06" > Java(TM) SE Runtime Environment (build 1.6.0_06-b02) > Java HotSpot(TM) Client VM (build 10.0-b22, mixed mode, sharing) > > Does the normal xine-ui (just xine on the command line) work fine on > your system (just trying to check everything) > > matthias > > > On Sep 23, 2008, at 7:18 AM, Kristian Lindemann Larsen wrote: > >> Hey >> I'm currently running kubuntu 8.04.1, manually installed jdk1.6.0_10 and >> developing in netbeans-6.1. >> When i try to run my program, the VM crashes aprox. 9/10 times when i >> try to bind the controller to the video canvas: >> >> engine.createController( video ); >> >> The vm dumps the following: >> >> # >> # An unexpected error has been detected by Java Runtime Environment: >> # >> # SIGSEGV (0xb) at pc=0x00007feebe8aca6d, pid=32602, tid=1097247056 >> # >> # Java VM: Java HotSpot(TM) 64-Bit Server VM (11.0-b15 mixed mode >> linux-amd64) >> # Problematic frame: >> # C [libxineJNI.so.0.0.0+0x1fa6d] xineJ_create_visual+0x35 >> # >> # An error report file with more information is saved as: >> # /home/walker/NetBeansProjects/TestVideo/hs_err_pid32602.log >> # >> # If you would like to submit a bug report, please visit: >> # http://java.sun.com/webapps/bugreport/crash.jsp >> # The crash happened outside the Java Virtual Machine in native code. >> # See problematic frame for where to report the bug. >> # >> Java Result: 134 > |
From: Matthias R. <mri...@in...> - 2008-09-23 15:54:18
|
Hi Kristian thanks for detailed crash report. On 23.09.2008, at 16:55, Kristian Lindemann Larsen wrote: > > When trying to configure (currently trying r375) i get the following > error: > ---------------------------- > ./configure --prefix=/opt/jdk1.6.0_10 > ... > checking for jawt_md.h... yes > Cannot find libjawt, please specify --with-jni-lib-flags. > ---------------------------- > I fix this by inserting the following line at line 22255 in configure: > JNI_LIB="-L/opt/jdk1.6.0_10/jre/lib/amd64/" That's fine, I'll try to add the amd64 subfolder to the search location. Could you also send me your config.log (you can sent this to me directly for this, if you want) ? > Then when trying to compile (make) i get the following error: > ---------------------------- > libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xineJ_1open': > libxine_wrap.c:1096: warning: cast to pointer from integer of > different size > libxine_wrap.c: In function > 'Java_org_libxine_XineLibJNI_xineJ_1create_1visual': > libxine_wrap.c:1116: warning: cast to pointer from integer of > different size > libxine_wrap.c: In function > 'Java_org_libxine_XineLibJNI_xineJ_1post_1init': > libxine_wrap.c:1181: warning: cast to pointer from integer of > different size > libxine_wrap.c: In function > 'Java_org_libxine_XineLibJNI_xine_1trick_1mode': > libxine_wrap.c:1533: warning: 'xine_trick_mode' is deprecated > (declared > at /usr/include/xine.h:261) > libxine_wrap.c: In function 'Java_org_libxine_XineLibJNI_xine_1vlog': > libxine_wrap.c:3297: error: incompatible types in assignment > make: *** [libxine_wrap.lo] Error 1 > ---------------------------- > i fix this by: > - arg4 = *argp4; > - xine_vlog(arg1,arg2,(char const *)arg3,arg4); > + xine_vlog(arg1,arg2,(char const *)arg3,*argp4); > > which makes it compile. Is this dangerous, and could this have > anything > to do with the crash? On my systems, there is only a single warning about xine_trick_mode beeing deprectated, no other warnings/error. I do belief that the warnings are a bad sign, and something goes wrong. I'll have to make me smart about 64-bit intel stuff and try to find a 64-bit intel machine for debugging. What happens is that on your platform each pointer is 64-bit wide and passing pointers between java and C is a bit tricky. Could you also sent me the generated libxine_warp.c? I don't think this is a hard problem, but it will requires beeing extra careful. Are all libarares on your system 64-bit wide? what's the output of e.g. file /usr/lib/libxine.so.1.24.0 ? Cheers, Matthias |
From: Matthias R. <mri...@in...> - 2008-09-26 08:54:55
|
Hi Kristian > I was very close to installing 32bit to get rid of the crashes, but on > the other hand, I thought i might give you some info on what was going > wrong, so you could fix the problem. You did that very fast, so no > problem :). thanks for your confidence. :) > I'm hoping to write some kind of wrap for container wrap for your > video > display, and a small framework of components for it. I hope to > create a > transparent way of creating components which can be used on > traditional > panels and as OSD component. > Something like: > > XineVideoContainer xvc = new XineAWTCanvasWrap(); > xvc.setLayout(new BorderLayout()); > xvc.add(new XButton("play")); > > ... or something. Haven't quite thought it through, but something to > make it easier and more (java)-intuitive to write UI's. hey, that sounds cool! we definitely need a OSD widget library. And, your toolkit approach could facilitate the development of UIs. The Xine{AWT,Swing,SWT}Canvas all provide mouse events, even in fullscreen mode. I could give you feedback on the architecture design, if you like. One thing to consider is the use of the color palette with 256 entries. In a PNG, the graphic tool would calculate the best set of colors to match the original image with the least difference. But, as you can imagine, this only helps as long as you only have a single image. When browsing the java classes for support for color palettes and image loading, I've found this: http://java.sun.com/j2se/1.4.2/docs/api/java/awt/image/BufferedImage.html#TYPE_BYTE_INDEXED BufferedImage uses a color palette where red, green, blue have a values from 0 to 5. this requires 6x6x6 = 216 colors and leaves 40 colors for general stuff and font-anti-aliasing. xine-lib uses 11 colors to draw an anti-aliased font. based on this, we could use a color resolution of about 2.58 bits per component (216), a gray scale of 6 levels, three different font colors (33) and a single completely transparent entry for the background. does this make sense? it would limit the image quality (a bit), but it is easy to manage. with the current XineOSD you can already try this out, although the image drawing does not work, yet. It works, but the colors are wrong, and the background gets green although it should just get BLACK (which is the first entry in the java color palette) . There must be something I did not understand yet. > anyway, nice work so far. If I were to develop directly in your java > source, how would you like me to suggest the changes to you? as > patches? I have not much experience with receiving and applying patches, but patches are commonly used for this, so let's try with patches first. cheers, matthias |