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: 4652208
Votes 18
Synopsis 1.4 FCS release - Large applications will not run with -Xrunhprof:cpu=times.
Category hotspot:jvmpi
Reported Against 1.4 , 1.4.1 , 1.3.1_04 , hopper-beta
Release Fixed 1.4.0_04
State 10-Fix Delivered, bug
Priority: 4-Low
Related Bugs 4519432 , 4723783
Submit Date 13-MAR-2002
Description
Please refer to Incident #144059 filed by  xxxxx  :

Registering interest in JVMPI_EVENT_METHOD_EXIT will occasionaly cause client JVMs to hang after an indeterminate amount of time.  The JVMs affected by this include

1.3.1_01
1.3.1_01a
1.3.1_02
1.4.0-b92

Platform -- at least win32 (reproduced on Win2K, NT4).

The 1.3.1-b24 JVM is not affected by this problem.

HPROF can be used to demonstrate this behaviour by adding "-Xrunhprof:cpu=times" to the command line arguments of the JVM.

A moderately large application is required in order to reproduce the problem.  Tomcat 4.0.1 or WebLogic6.1sp2 are  customer  candidates -- the hang occurs on startup (between 1 and 2 minutes into running the application). For the 1.3.1_0x JVMs, the hang does not cause the application to exit -- the JVM becomes unresponsive and does not report any errors.  The 1.4 JVM exits with the error printed below.  The hang does not occur every run.

-------------- sample Tomcat 4 run --------------
E:\>e:\j2sdk1.4.0\bin\java.exe -hotspot -Xrunhprof:cpu=times -Dcatalina.home=e:\tomcat4 -
Dcatalina.base=e:\tomcat4 -classpath e:\tomcat4\bin;e:\tomcat4\bin\bootstrap.jar
 org. customer .catalina.startup.Bootstrap start
HPROF ERROR: thread local table NULL in method exit 0AA10684
HPROF ERROR: thread local table NULL in method exit 0AA10684
HPROF ERROR: thread local table NULL in method exit 0023D4E4
HPROF ERROR : stack underflow in method exit
HPROF ERROR : stack underflow in method exit
Starting service Tomcat-Standalone
 customer  Tomcat/4.0.1
#
# HotSpot Virtual Machine Error, Internal Error
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Java VM: Java HotSpot(TM) Client VM (1.4.0-b92 mixed mode)
#
# Error ID: 43113F32554E54494D45110E435050034A
#
# Problematic Thread: prio=5 tid=0x00234B20 nid=0x334 runnable
#

----------- end sample Tomcat 4 run -------------

HPROF reports stack problems regardless of whether the hang (or crash for the 1.4 JVM) occurs.

The following code can be used as 'the simplest' JVMPI client able to  reproduce the problem:

----------- sample code -------------

#include <jvmpi.h>

JVMPI_Interface * jvmpi;
static void notify(JVMPI_Event *);

JNIEXPORT jint JNICALL
JVM_OnLoad(JavaVM * jvm, char * options, void * reserved) {

	(*jvm)->GetEnv(jvm, (void **) &jvmpi, JVMPI_VERSION_1);
	jvmpi->NotifyEvent = notify;
	jvmpi->EnableEvent(JVMPI_EVENT_METHOD_EXIT, 0);
	return JNI_OK;
}

static void
notify(JVMPI_Event * event) {
	return;
}

-------------------------

I ran the same test on Windows 2000 machine using Tomcat 4.0 (Modified catalina.bat script to include -Xrunhprof:cpu=times) and Java 1.4 FCS (buld 92). I can see HPROF errors, but the crash is not consistent. Tomcat is running fine some times, but fails some other times. There are many bug reports filed for similar issue, but could not find any thing which matches exactly the same description.

  xxxxx@xxxxx   - 03/13/ customer .
----------------------------------
Work Around
N/A
Evaluation
  xxxxx@xxxxx   2002-11-22

This bug is not reproducible with Mantis. I'm almost 100% certain that
this bug is fixed by Tom R's fix for:

4731114 2/1 hprof:cpu=times crashes with 1.4.1 (hopper) rc build 19 with
            -client on windows.

I believe this bug should be closed as a duplicate of 4731114, but I
don't know what that would mean for Rob Mckenna's backport to 1.4.0_04.
I'll check with Rob before doing anything further.

Meanwhile, we can take this off the Mantis radar.
Comments
  
  Include a link with my name & email   

Submitted On 05-APR-2002
joviru
Same problem with 1.4.0-b92(Win2K,Tomcat4) - the 1.3.1-b24 
JDK works fine. But the real problem - we used a Debug 
class with a assert function (now a Java Keyword). After 
rename this function the VM didn't crash again.  


Submitted On 12-APR-2002
Dens666
I Tried to run my classes under Debian Linux. No problem.
So this is stricly an issue of for JVM 1.4.0/windows for me. 


Submitted On 12-APR-2002
Dens666
I Also have this Error ID but for something completely different (in some WarehouseImpl inside my RMI Server). Didn't found any workaround. Bug occurs 100% of the time in mixed or interpreted mode. It doesn't occur with 1.3.1 
OS: Win XP Pro
Just Wondering how it is possible to have same Error IDs with so different BUGs...


Submitted On 06-MAY-2002
bryce777
I have the same error message, and yet another error.

I do some complexs tuff including a DB query then I have a nullpointer exception on a line that looks like:

if(myHashtable==null||myHashtable.length<1)
return;

This should not ever happen.

I use Oracle 8.17, patched, with the latest drivers (which are for java 1.2!).

I may be crazy, but since the bug happens every time I think it has something to do with the Oracle drivers.

I imagine either there is a name/classloading conflict or something.

If not that, I use reflection heavily, so it could be that the reflection methods are doing something unsafe in another thread somehow.

Bug is definitely repeatable, happens every time, but my application is far to large for sun to debug....


Submitted On 06-MAY-2002
bryce777
Forgive my typos above, please


Submitted On 12-JUN-2002
csallnch
Same errorID produced by the following code on windows xp 
and solaris 
HotSpot(TM) Client VM (build 1.4.0-b92, mixed mode):

package errorID43113F32554E54494D45110E435050034A;

public class Test {

	interface A {String toString();}

	interface B extends A {}
	
	static class C implements B {}

	public static void main(String[] args) {
		B v = new C();
		System.out.println(v.toString());
	}
}


Submitted On 26-AUG-2002
Ernimril
Also tested with 
java version "1.4.1-rc"
Java(TM) 2 Runtime Environment, Standard Edition (build
1.4.1-rc-b19)
Java HotSpot(TM) Client VM (build 1.4.1-rc-b19, mixed mode)

Still crashes



PLEASE NOTE: JDK6 is formerly known as Project Mustang