harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gregory Shimansky (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (HARMONY-3376) [drlvm][winx64] debug drlvm returns 128 when running from any shell
Date Thu, 15 Mar 2007 13:38:09 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-3376?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

Gregory Shimansky resolved HARMONY-3376.

    Resolution: Fixed

The problem appears to be in recursive exception handler invocation. When VM shutdowns it
frees and zeroes a pointer to vm_methods table which contains all compiled java methods information.
This table is used by exception handler to determine whether an exception has occurred in
java code or in any other code.

So after VM zeroed a pointer to vm_methods, when exception handler tried to determine where
an exception has occurred, it got another exception because it used an incorrect pointer.
This lead to an infinite recursion of exception handler and eventual process termination with
an error code 128.

The reason why exception handler was called after VM shutdown seems to be the MSVC runtime.
Somewhere after main function of the java.exe launcher has finished, MSVC runtime generated
an exception with code 0x406D1388. This exception happens both on windows x86 and x86_64 if
the program is compiled with MSVC 2005 and linked with msvcr80.dll.

The fix to this problem is that if the pointer to vm_method table is zero, no lookup should
be performed in it. If this pointer is zero, then it means that exception didn't occur in
java because java cannot be executed in such condition. Patch to fix this applied at 518625.
Please check that it fixes the problem.

> [drlvm][winx64] debug drlvm returns 128 when running from any shell
> -------------------------------------------------------------------
>                 Key: HARMONY-3376
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3376
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: windows/em64t
>            Reporter: Pavel Pervov
>         Assigned To: Gregory Shimansky
>            Priority: Minor
> When DRLVM is being run from any shell (cygwin bash or cmd) the process return code is
128. 'main' function exits with code 0. It looks like some problem in runtime shutdown.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message