Re: [rvm-research] Question about MarkSweep, AllocAsMarked

Robin Garner <[email protected]>
Newsgroups gmane.comp.java.jikes.rvm.devel
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

That's easy.

The SegregatedFreeList allocator maintains two sets of blocks, those
that have either been allocated into or are currently being allocated
into since the most recent GC, and those that have not.

Blocks are swept when they are taken from the latter and before they
are allocated into.  In the standard MarkSweep collector, we never
sweep blocks that have been allocated into since the most recent GC.

The only case where you need to allocate objects in the marked state
is in the Concurrent MS collector, where objects allocated during a
mark phase need to be allocated as marked.

cheers,
Robin

On 08/02/14 03:55, Nathan Ricci wrote:
> 
> 
> I was looking through the code for MarkSweepSpace, and I noticed 
> there is a boolean "isAllocAsMarked" which can be set through the
> public method makeAllocAsMarked.
> 
> It seems like, if this boolean is false, objects are not marked 
> when they are allocated, instead having their GCHeaderByte set to 
> something called the "allocState" (which, if I am reading the code 
> correctly, has the value of the previous mark state).
> 
> The default seems to be that isAllocAsMarked is false. But I can't 
> quite figure out how this is correct; how does the sweeper avoid 
> sweeping newly allocated (and still possibly live) objects if they
> do not have their mark bits set on allocation?
> 
> --Nathan
> 
> 
> 
> 
> ------------------------------------------------------------------------------
>
> 
Managing the Performance of Cloud-Based Applications
> Take advantage of what the Cloud has to offer - Avoid Common
> Pitfalls. Read the Whitepaper. 
> http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
>
> 
> 
> 
> _______________________________________________ 
> Jikesrvm-researchers mailing list 
> [email protected] 
> https://lists.sourceforge.net/lists/listinfo/jikesrvm-researchers
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJS+A/fAAoJEHm9xBvoMhvaF1UH/2VepvVhBz/godZz2cvsut/3
WcUDaXcfxvinhv0VW8TWwO2mJYjyxYFWe/puQOz0uit7Na1pIoxZQlSPMwtL9h88
p0KY7bZwvXMu5cwycg7jLTUM3xTiCVDebbX0CZM6q08dGl+SHsGZd+icRNc3QqBv
FWZXUk974T3j8xRZMnpehY9xG6PwNbpniD/CrLwXoScr2cyL8ZFB7TEP0srhrBri
iN7hyhgGZ22BFeA9L24bbp2FwkGpBj+tDZXAG6G17Y32TCnLV0lzffoGnQhVmCl+
6XDP6tX/WSdJLQh8niee5j4HzXxd0lvu/CXbrruyWKYEddRpHcOknTPwmi3q+bM=
=rhf7
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.