Automatic memory management algorithm--tagging method

Source: Internet
Author: User

Recently read the "Garbage Collection Algorithm Handbook" This classic book, take this opportunity to write a few memory management algorithm aspects of the article, but also a summary of it.

                                                                                                                                                                            --Preface

Automatic Memory Management System

Automatic memory management is mainly faced with the following three tasks:

1. Allocating memory space for new objects

2. Determine the "surviving" object

3. Reclaim the memory space occupied by the "dead" object

Where task 1 is generally referred to as "Automatic memory allocation" (MemoryAllocation, hereinafter referredto as MA), Task 2, 3 is often said "garbage collector" (garbage Collect is GC, hereinafter referred to as GC). In general, in order to reduce the complexity and stability of the automatic memory management system design, the general use of single-threaded design, that is, the MA and GC can not be simultaneous, which explains some managed code in the case of a large number of GC scenarios, because the GC thread is running, the MA thread will wait, That is, managed code pauses execution until the GC ends, and if the GC is running longer, the program will become more noticeable.

Automatic memory management algorithm--tagging method

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.