harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "weldon washburn (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-4727) [drlvm][thread] explicit allocation/deallocation of VM_thread structure
Date Wed, 05 Sep 2007 05:44:32 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-4727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12524989
] 

weldon washburn commented on HARMONY-4727:
------------------------------------------

Pavel,

Yes you are correct.  Patch xxx01.patch and xxx02.patch are not correct at all.

I have done some additional thinking.  I suspect there are three bugs:

1)
When a java thread creates a new java thread, jthread_wrapper_proc() calls vm_attach().  But
by the time vm_attach() is called, the thread is already gc enumerable.  This is a problem
because things like M2NFrame are created in vm_attach().  In other words, its too late.

2)
The above situation is duplicated in JNI_CreateJavaVM(), AttachCurrentThread(), AttachCurrentThreadAsDaemon(),
DestroyJavaVM().  In other words, we have two places in Thread Manager that need cleaned up.

3)
Somehow vm_shutdown_callback() calls hythread_detach() for each live java thread but forgets
to call jthread_detach().  Attached is a candidate patch (shutdown.patch) that tries to fix
this problem.  So far about 1/2 of "build test" has run and this patch seems OK.

> [drlvm][thread] explicit allocation/deallocation of VM_thread structure 
> ------------------------------------------------------------------------
>
>                 Key: HARMONY-4727
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4727
>             Project: Harmony
>          Issue Type: Sub-task
>          Components: DRLVM
>            Reporter: weldon washburn
>         Attachments: explicit_alloc_and_dealloc_01.patch, explicit_alloc_and_dealloc_02.patch,
shutdown.patch
>
>


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


Mime
View raw message