harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ivan Volosyuk (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-1556) [DRLVM][finalizers] Race condition between classloader and finalizers subsystem
Date Fri, 22 Sep 2006 23:56:22 GMT
[DRLVM][finalizers] Race condition between classloader and finalizers subsystem

                 Key: HARMONY-1556
                 URL: http://issues.apache.org/jira/browse/HARMONY-1556
             Project: Harmony
          Issue Type: Bug
          Components: DRLVM
         Environment: reproduced on Linux
            Reporter: Ivan Volosyuk

Race condition sometimes reproducible on gc.PhantomReferenceQueueTest smoke test.
Leads to crash with following message:
  classloader.cpp:549: void ClassLoader::SuccessLoadingClass(const String*): Assertion `lc'

Classloader detects collisions and CircularityError before crash.

The problem is:
   During resolution of some class 'java/lang/InternalError' referenced in 'java/lang/Object'
from gc_alloc() function is called vm_hint_finalize() which executes java code. The code also
does resolution of the same class and reports 'CircularityError' removing the class from m_loadingClasses.
The assertion fails in the first place of resolution.

0x8636f70 0x807d6d8 R java/lang/Thread
0x80b1b88 0x807d6d8 I java/lang/InternalError
0x80b1b88 0x807d6d8 DC java/lang/InternalError
0x80b1b88 0x807d6d8 CDAI 0x807d6d8 java/lang/InternalError

Breakpoint 3, ClassLoader::StartLoadingClass (this=0x80b1b88, env=0xb6fdca80,
    at /home/ivan/svn/drlvm/trunk/vm/vmcore/src/class_support/classloader.cpp:782
782                     FailedLoadingClass(className);
(gdb) p cur_thread
$1 = (VM_thread *) 0x807d6d8
(gdb) p st_print()
Stack Trace (0x807d6d8):
  [0x807d6d8] (nil)(n): *null*
  [0x807d6d8] 0xb6827ff7(m): java/lang/ref/ReferenceQueue.enqueue(Ljava/lang/ref/Reference;)Z
  [0x807d6d8] 0xb6827ebe(m): java/lang/ref/Reference.enqueue()Z
  [0x807d6d8] 0xb6d68fd8(n): *null*
  [0x807d6d8] 0xb68277e8(m): java/lang/FinalizerThread.run()V
  [0x807d6d8] 0xb68271fa(m): java/lang/Thread.runImpl()V
  [0x807d6d8] 0xb6d68fd8(n): *null*
End Stack Trace (0x807d6d8, depth=7)

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message