FIX: Java Applet / Application Causes Error Code 0xc000001d

ID: Q245643


The information in this article applies to:
  • Microsoft virtual machine


SYMPTOMS

When running Java code with the JIT compiler turned on, some uses of character constants in a loop can cause an Application error to occur. This article describes one example of code that causes an Application error and results in the following error message:

JView.exe - Application Error
The exception Illegal Instruction.
An attempt was made to execute an illegal instruction.
(0xc000001d) occurred in the application at location 0x04041332. Click on OK to terminate the program. Click on CANCEL to debug the program.


CAUSE

This problem is caused by a bug in the way that the JIT compiler handles character constants when unrolling a loop.


STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article.

This problem has been fixed in version 3190 and 3236 of the Microsoft virtual machine.


MORE INFORMATION

This code causes the Application error and results in the error message in the "Symptoms" section:


public class Test
{           
    private static void DoTest()
    {
        for( int i = 0; i < 10; i++ )
        {
            System.out.println( (char)('a' + i) );
        }
    }

    public static void main( String[] args )
    {
        System.out.println( "starting" );

        DoTest();
    }
}  

© Microsoft Corporation 2000, All Rights Reserved.
Contributions by Robert LaCasse, Microsoft Corporation


REFERENCES

For the latest Knowledge Base articles and other support information on Visual J++ and the SDK for Java, please see the following pages on the Microsoft Technical Support site:

http://support.microsoft.com/support/visualj/

http://support.microsoft.com/support/java/

Additional query words:

Keywords : kbCompiler kbJavaVM kbJIT kbGrpJava kbDSupport
Version : WINDOWS:
Platform : WINDOWS
Issue type : kbbug


Last Reviewed: February 2, 2000
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.