You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Ivan Volosyuk (JIRA)" <ji...@apache.org> on 2006/10/06 18:05:19 UTC

[jira] Created: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

[DRLVM][GC] weak references reachable from finalizible objects is not enumerated
--------------------------------------------------------------------------------

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


Weak references processing is splited into 2 phases on compaction algorithm.
1 phase: check reachability of referent, remember the reference or referent for update during compaction.
2 phase: vm_enqueue_reference() if the referent is not reachable.

Algorithm of enumeration is the following:
enumerate world
enumerate (phase1) process weak and soft references
enumerate finalizible objects.
compaction
enqueue weak and soft references
....

Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Commented: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/HARMONY-1762?page=comments#action_12440504 ] 
            
Ivan Volosyuk commented on HARMONY-1762:
----------------------------------------

The bug is the stability bug. It can be reproduced occasionally on different scenarious.

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Commented: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/HARMONY-1762?page=comments#action_12441107 ] 
            
Ivan Volosyuk commented on HARMONY-1762:
----------------------------------------

After reorganization the patch can be applied following way:
cd vm/gc_cc; patch -p3 < special_references_fix.diff

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Commented: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Geir Magnusson Jr (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/HARMONY-1762?page=comments#action_12442339 ] 
            
Geir Magnusson Jr commented on HARMONY-1762:
--------------------------------------------

Applied, results in a different stack trace : 

.java: /home/geir/dev/apache/harmony/enhanced/trunk/working_vm/vm/vmcore/include/object_layout.h:72: VTable* ManagedObjectUncompressedVtablePtr::vt(): Assertion `vt_raw' failed.
SIGABRT in VM code.
Stack trace:
addr2line: '[vdso]': No such file
        1: ?? (�嶈����Yʶ:-1)
j

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

       

[jira] Updated: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Ivan Volosyuk updated HARMONY-1762:
-----------------------------------

    Attachment: special_references_fix2.diff

True, only a half of problem is fixed in previous patch.

New weak references detected after processing finalizible objects cannot be safely ignored. Their slots should be updated according to reachability of referents.

Fixed in new patch:
Added one more phase to update weak and soft references detected after marking of all finalizible objects.
No more phases needed even for arbitrary length of dependent weak and finalizible object chains, as no more objects will be revived at this GC.

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff, special_references_fix2.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Updated: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Ivan Volosyuk updated HARMONY-1762:
-----------------------------------

    Attachment: FinGC.java

Test to reproduce the problem.
Finalizible object reachable via WeakReference containing reference to WeakReference.

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Resolved: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Geir Magnusson Jr (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Geir Magnusson Jr resolved HARMONY-1762.
----------------------------------------

    Resolution: Fixed

r464099

Ubuntu 6 - smoke, c-unit, ~kernel

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Assigned To: Geir Magnusson Jr
>         Attachments: FinGC.java, special_references_fix.diff, special_references_fix2.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Commented: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Geir Magnusson Jr (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/HARMONY-1762?page=comments#action_12442357 ] 
            
Geir Magnusson Jr commented on HARMONY-1762:
--------------------------------------------

much better :)  thx

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff, special_references_fix2.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Closed: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Geir Magnusson Jr (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Geir Magnusson Jr closed HARMONY-1762.
--------------------------------------


> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Assigned To: Geir Magnusson Jr
>         Attachments: FinGC.java, special_references_fix.diff, special_references_fix2.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Commented: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/HARMONY-1762?page=comments#action_12440500 ] 
            
Ivan Volosyuk commented on HARMONY-1762:
----------------------------------------

Test contains infinite loop. With the bug it fails after a few GCs.

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Updated: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Ivan Volosyuk (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Ivan Volosyuk updated HARMONY-1762:
-----------------------------------

    Attachment: special_references_fix.diff

Fix attached.
Ignore new weak references reported from objects reachable via finalizible objects.

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Attachments: FinGC.java, special_references_fix.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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

        

[jira] Assigned: (HARMONY-1762) [DRLVM][GC] weak references reachable from finalizible objects is not enumerated

Posted by "Geir Magnusson Jr (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/HARMONY-1762?page=all ]

Geir Magnusson Jr reassigned HARMONY-1762:
------------------------------------------

    Assignee: Geir Magnusson Jr

> [DRLVM][GC] weak references reachable from finalizible objects is not enumerated
> --------------------------------------------------------------------------------
>
>                 Key: HARMONY-1762
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1762
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>         Environment: All
>            Reporter: Ivan Volosyuk
>         Assigned To: Geir Magnusson Jr
>         Attachments: FinGC.java, special_references_fix.diff, special_references_fix2.diff
>
>
> Weak references processing is splited into 2 phases on compaction algorithm.
> 1 phase: check reachability of referent, remember the reference or referent for update during compaction.
> 2 phase: vm_enqueue_reference() if the referent is not reachable.
> Algorithm of enumeration is the following:
> enumerate world
> enumerate (phase1) process weak and soft references
> enumerate finalizible objects.
> compaction
> enqueue weak and soft references
> ....
> Enumeration of finalizible objects may add more weak references which was not enumerated, but which will be enqueued. This is the enumeration problem.

-- 
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