Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 6500626
Votes 2
Synopsis VM crash on callng JNI_CreateJavaVM()
Category hotspot:runtime_system
Reported Against
Release Fixed
State 11-Closed, duplicate of 6346124, bug
Priority: 3-Medium
Related Bugs 6346124 , 4644270 , 6457572
Submit Date 05-DEC-2006
Description
FULL PRODUCT VERSION :
Java VM: Java HotSpot(TM) Client VM (1.6.0-rc-b104 mixed mode, sharing)

FULL OS VERSION :
Windows 2000 Pro SP 4 [5.0.2195] German

A DESCRIPTION OF THE PROBLEM :
All I do is calling JNI_CreateJavaVM()
With -Xcheck:jni enabled I got the following warning:
Java HotSpot(TM) Client VM warning: Floating point control word changed by nativ
e JNI code.

Without Xcheck:jni enabled the VM crashes with the following info in the hs_err_pidXXX.log file.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Just call JNI_CreateJavaVM

Attached is the test program to reproduce the warning. It´s written in Delphi but there should no difference to C/C++ cause it´s very simple and calling the JNI_CreateJavaVM() from JVM.DLL only. The source is inlcuded and documented.

It´s a simple Console application

ERROR MESSAGES/STACK TRACES THAT OCCUR :

#
# An unexpected error has been detected by Java Runtime Environment:
#
#  EXCEPTION_FLT_STACK_CHECK (0xc0000092) at pc=0x00dbce69, pid=744, tid=756
#
# Java VM: Java HotSpot(TM) Client VM (1.6.0-rc-b104 mixed mode, sharing)
# Problematic frame:
# v  ~RuntimeStub::resolve_opt_virtual_call
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
#

---------------  T H R E A D  ---------------

Current thread (0x00d45400):  JavaThread "main" [_thread_in_Java, id=756]

siginfo: ExceptionCode=0xc0000092, ExceptionInformation=0x00000000 0x0012f054

Registers:
EAX=0x22933b58, EBX=0x22933b88, ECX=0x22933b58, EDX=0x0000001b
ESP=0x0012efe8, EBP=0x0012f0f8, ESI=0x22909680, EDI=0x0000001b
EIP=0x00dbce69, EFLAGS=0x00010216

  Top of Stack: (sp=0x0012efe8)
0x0012efe8:   ffff1372 ffff0020 ffffffff 6d983a47
0x0012eff8:   0344001b 0012f3e0 ffff0023 00000000
0x0012f008:   00000000 00000000 00000000 00000000
0x0012f018:   00000000 00000000 00000000 00000000
0x0012f028:   00000000 00000000 00000000 00000000
0x0012f038:   5be00000 4005c805 00000000 80000000
0x0012f048:   00004002 00000000 00000000 00d45ec4
0x0012f058:   00120001 00d45ec4 00d45ec8 00000000

Instructions: (pc=0x00dbce69)
0x00dbce59:   00 00 83 ec 6c dd 34 24 9b dd 24 24 dd 5c 24 6c
0x00dbce69:   dd 5c 24 74 dd 5c 24 7c dd 9c 24 84 00 00 00 dd


Stack: [0x00030000,0x00130000),  sp=0x0012efe8,  free space=1019k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
v  ~RuntimeStub::resolve_opt_virtual_call
J  sun.nio.cs.UTF_8$Decoder.decodeArrayLoop(Ljava/nio/ByteBuffer;Ljava/nio/CharBuffer;)Ljava/nio/charset/CoderResult;
j  sun.nio.cs.UTF_8$Decoder.decodeLoop(Ljava/nio/ByteBuffer;Ljava/nio/CharBuffer;)Ljava/nio/charset/CoderResult;+17
j  java.nio.charset.CharsetDecoder.decode(Ljava/nio/ByteBuffer;Ljava/nio/CharBuffer;Z)Ljava/nio/charset/CoderResult;+57
j  java.lang.StringCoding$StringDecoder.decode([BII)[C+58
j  java.lang.StringCoding.decode(Ljava/lang/String;[BII)[C+116
j  java.lang.String.<init>([BIILjava/lang/String;)V+30
j  java.util.jar.Attributes.read(Ljava/util/jar/Manifest$FastInputStream;[B)V+292
j  java.util.jar.Manifest.read(Ljava/io/InputStream;)V+291
j  java.util.jar.Manifest.<init>(Ljava/io/InputStream;)V+28
j  java.util.jar.JarFile.getManifestFromReference()Ljava/util/jar/Manifest;+60
j  java.util.jar.JarFile.getManifest()Ljava/util/jar/Manifest;+1
j  sun.misc.URLClassPath$JarLoader$2.getManifest()Ljava/util/jar/Manifest;+7
j  java.net.URLClassLoader.defineClass(Ljava/lang/String;Lsun/misc/Resource;)Ljava/lang/Class;+35
j  java.net.URLClassLoader.access$000(Ljava/net/URLClassLoader;Ljava/lang/String;Lsun/misc/Resource;)Ljava/lang/Class;+3
j  java.net.URLClassLoader$1.run()Ljava/lang/Object;+43
v  ~StubRoutines::call_stub


---------------  P R O C E S S  ---------------

Java Threads: ( => current thread )
  0x02efcc00 JavaThread "Low Memory Detector" daemon [_thread_new, id=1392]
  0x02ef7c00 JavaThread "CompilerThread0" daemon [_thread_blocked, id=240]
  0x02ef6800 JavaThread "Attach Listener" daemon [_thread_new, id=1344]
  0x02ef5800 JavaThread "Signal Dispatcher" daemon [_thread_new, id=568]
  0x02ef0c00 JavaThread "Finalizer" daemon [_thread_new, id=1048]
  0x02eefc00 JavaThread "Reference Handler" daemon [_thread_blocked, id=1496]
=>0x00d45400 JavaThread "main" [_thread_in_Java, id=756]

Other Threads:
  0x02ee6800 VMThread [id=1196]
  0x02efe800 WatcherThread [id=1008]

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap
 def new generation   total 960K, used 212K [0x22900000, 0x22a00000, 0x22de0000)
  eden
[error occurred during error reporting, step 190, id 0xc0000092]

Dynamic libraries:
0x00400000 - 0x0042b000 	C:\Jts\TwsVer.exe
0x77880000 - 0x77902000 	C:\WINNT\system32\ntdll.dll
0x77e70000 - 0x77f31000 	C:\WINNT\system32\kernel32.dll
0x77e00000 - 0x77e69000 	C:\WINNT\system32\user32.dll
0x77f40000 - 0x77f7c000 	C:\WINNT\system32\GDI32.dll
0x79350000 - 0x793b5000 	C:\WINNT\system32\advapi32.dll
0x77d20000 - 0x77d8f000 	C:\WINNT\system32\RPCRT4.dll
0x779a0000 - 0x77a3b000 	C:\WINNT\system32\oleaut32.dll
0x7ce80000 - 0x7cf6f000 	C:\WINNT\system32\ole32.dll
0x6d7c0000 - 0x6da07000 	C:\Programme\Java\jre1.6.0\bin\client\jvm.dll
0x77540000 - 0x77571000 	C:\WINNT\system32\WINMM.dll
0x7c340000 - 0x7c396000 	C:\WINNT\system32\MSVCR71.dll
0x6d310000 - 0x6d318000 	C:\Programme\Java\jre1.6.0\bin\hpi.dll
0x68f30000 - 0x68f3b000 	C:\WINNT\system32\PSAPI.DLL
0x6d770000 - 0x6d77c000 	C:\Programme\Java\jre1.6.0\bin\verify.dll
0x6d3b0000 - 0x6d3cf000 	C:\Programme\Java\jre1.6.0\bin\java.dll
0x6d7b0000 - 0x6d7bf000 	C:\Programme\Java\jre1.6.0\bin\zip.dll

VM Arguments:
java_command: <unknown>
Launcher Type: generic

Environment Variables:
PATH=C:\WINNT\system32;C:\WINNT;C:\WINNT\System32\Wbem;C:\Delphi\Bin;C:\Delphi\Projects\Bpl
USERNAME=Bodo Joest
OS=Windows_NT
PROCESSOR_IDENTIFIER=x86 Family 15 Model 2 Stepping 9, GenuineIntel



---------------  S Y S T E M  ---------------

OS: Windows 2000 Build 2195 Service Pack 4

CPU:total 1 family 15, cmov, cx8, fxsr, mmx, sse, sse2, ht

Memory: 4k page, physical 1047792k(697188k free), swap 2518436k(2214000k free)

vm_info: Java HotSpot(TM) Client VM (1.6.0-rc-b104) for windows-x86, built on Nov  1 2006 00:43:22 by "java_re" with unknown MS VC++:1310

THE PROBLEM WAS REPRODUCIBLE WITH -Xint FLAG: Did not try

THE PROBLEM WAS REPRODUCIBLE WITH -server FLAG: Did not try

REPRODUCIBILITY :
This bug can be reproduced always.
Posted Date : 2006-12-05 05:31:35.0
Work Around
N/A
Evaluation
Please address this as part of 6346124.
Posted Date : 2007-02-12 19:32:05.0
Comments
  
  Include a link with my name & email   

Submitted On 27-DEC-2006
EDemch
Could I add my small comment? The bug shows up not only after calling JNI_CreateJavaVM, but just on using any dll, compiled by Borland C Builder.

Yes, with JRE1.5.0 the same code works fine, and after adding -Xcheck:jni for 1.6 - it works also and gives the same warning as in the bug description, so I decided not to post it as a separate bug.

Here is my hotspot log:
#
# An unexpected error has been detected by Java Runtime Environment:
#
# EXCEPTION_FLT_STACK_CHECK (0xc0000092) at pc=0x0094d269, pid=2988, tid=2000
#
# Java VM: Java HotSpot(TM) Client VM (1.6.0-b105 mixed mode)
# Problematic frame:
# v ~RuntimeStub::resolve_static_call
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#

--------------- T H R E A D ---------------

Current thread (0x491b5c00): JavaThread "¨l§º¨l¨`¨l¨Y¨h§¨¨l¨Y¨l&#9617;¨l¨[¨l¨Y¨l¨Z¨l&#9617;¨h§¨¨l¨Y¨h§± ¨l§¾¨l§¿¨l§Ò-¨h§¢¨l¨e¨h§¡¨l¨ˆ¨l¨e¨h§¡¨l&#9617;..." daemon [_thread_in_Java, id=2000]

siginfo: ExceptionCode=0xc0000092, ExceptionInformation=0x00000000 0x49c4e7e4 

Registers:
EAX=0x429a8918, EBX=0x429a8918, ECX=0x029db8a8, EDX=0x00000000
ESP=0x49c4e778, EBP=0x49c4e888, ESI=0x00000000, EDI=0x00000013
EIP=0x0094d269, EFLAGS=0x00010216

Top of Stack: (sp=0x49c4e778)
0x49c4e778: ffff1272 ffff0020 ffffffff 6d983a27
0x49c4e788: 0000001b 49c4e780 ffff0023 00000d0d
0x49c4e798: f354b7c0 0001cb78 b4c00000 b8dcf354
0x49c4e7a8: bf986924 bf994280 277affff cb88bf81
0x49c4e7b8: b548e18e f354b65c 00000000 00000d0d
0x49c4e7c8: 00000000 3fff8000 00000000 c0000000
0x49c4e7d8: 00004000 00000000 00000000 491b5c00
0x49c4e7e8: 00922d95 6499d9bd 6499d9bd 49c4e7f4 

Instructions: (pc=0x0094d269)
0x0094d259: 00 00 83 ec 6c dd 34 24 9b dd 24 24 dd 5c 24 6c
0x0094d269: dd 5c 24 74 dd 5c 24 7c dd 9c 24 84 00 00 00 dd 


Stack: [0x49c00000,0x49c50000), sp=0x49c4e778, free space=313k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
v ~RuntimeStub::resolve_static_call
J java.lang.String.<init>([BIII)V
j java.util.jar.Attributes.read(Ljava/util/jar/Manifest$FastInputStream;[B)V+239 



PLEASE NOTE: JDK6 is formerly known as Project Mustang