You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Sergey Salishev (JIRA)" <ji...@apache.org> on 2007/05/17 13:49:16 UTC

[jira] Created: (HARMONY-3892) Deadlock during thread creation from custom sytem classloader

Deadlock during thread creation from custom sytem classloader
-------------------------------------------------------------

                 Key: HARMONY-3892
                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
             Project: Harmony
          Issue Type: Bug
          Components: DRLVM
         Environment: Windows, Linux
            Reporter: Sergey Salishev
         Attachments: ClassLoader0.java

The deadlock manifests when running the attached testcase with 

java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Commented: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Gregory Shimansky (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12497882 ] 

Gregory Shimansky commented on HARMONY-3892:
--------------------------------------------

I think there is no reason to load a class when we already have an instance object of it. Class loading always does lookup through class loader's tables while GetObjectClass simply retrieves the pointer to VT. It is more effective IMHO.

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Assigned To: Gregory Shimansky
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Closed: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Gregory Shimansky (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gregory Shimansky closed HARMONY-3892.
--------------------------------------


No response, assuming ok.

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>            Assignee: Gregory Shimansky
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Updated: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Pavel Pervov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pavel Pervov updated HARMONY-3892:
----------------------------------

    Attachment: H3892.patch

This patch is to fix the issue.

The idea is simple: since we have thread object, there is no need to FindClass - we can GetObjectClass from that thread object.

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Updated: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Gregory Shimansky (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gregory Shimansky updated HARMONY-3892:
---------------------------------------

    Patch Info: [Patch Available]
      Assignee: Gregory Shimansky

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Assigned To: Gregory Shimansky
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Commented: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Pavel Pervov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12497786 ] 

Pavel Pervov commented on HARMONY-3892:
---------------------------------------

This is the deadlock between ClassLoader0 and ClassLoader0 which occurs through thread starting code.

_alarmThread.start() calls Thread.lock.wait() inside synchronized ClassLoader0 and waits until target thread is started. Thread starting code calls to FindClass("java/lang/Thread") which in turn calls to ClassLoader0.loadClass.

Looks like I know the way. :) Will try to fix fast.

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Attachments: ClassLoader0.java
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Updated: (HARMONY-3892) Deadlock during thread creation from custom sytem classloader

Posted by "Sergey Salishev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sergey Salishev updated HARMONY-3892:
-------------------------------------

    Attachment: ClassLoader0.java

> Deadlock during thread creation from custom sytem classloader
> -------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Attachments: ClassLoader0.java
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Resolved: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Gregory Shimansky (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gregory Shimansky resolved HARMONY-3892.
----------------------------------------

    Resolution: Fixed

Patch applied at 540700. The attached class loader seems to work ok now.

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Assigned To: Gregory Shimansky
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Commented: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Alexey Varlamov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12497855 ] 

Alexey Varlamov commented on HARMONY-3892:
------------------------------------------

Nifty hack ;)
Is there such a strong design limitation to not ever use OPEN headers in TM? 
Otherwise class_load_class_by_name_using_bootstrap_class_loader() should work much better?

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Attachments: ClassLoader0.java, H3892.patch
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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


[jira] Updated: (HARMONY-3892) [drlvm][thread] Deadlock during thread creation from custom sytem classloader

Posted by "Gregory Shimansky (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-3892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gregory Shimansky updated HARMONY-3892:
---------------------------------------

    Summary: [drlvm][thread] Deadlock during thread creation from custom sytem classloader  (was: Deadlock during thread creation from custom sytem classloader)

> [drlvm][thread] Deadlock during thread creation from custom sytem classloader
> -----------------------------------------------------------------------------
>
>                 Key: HARMONY-3892
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3892
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: Windows, Linux
>            Reporter: Sergey Salishev
>         Attachments: ClassLoader0.java
>
>
> The deadlock manifests when running the attached testcase with 
> java -Djava.system.class.loader=ClassLoader0 bla

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