From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: please help about the implementation of GC. Date: Sun, 30 Oct 2011 19:53:54 +0200 Message-ID: <838vo28ix9.fsf@gnu.org> References: Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1319997248 3063 80.91.229.12 (30 Oct 2011 17:54:08 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 30 Oct 2011 17:54:08 +0000 (UTC) Cc: as1789@gmail.com, emacs-devel@gnu.org To: Andreas Schwab Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Oct 30 18:54:04 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RKZa7-0004kh-Bz for ged-emacs-devel@m.gmane.org; Sun, 30 Oct 2011 18:54:03 +0100 Original-Received: from localhost ([::1]:52107 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RKZa6-0001kV-OF for ged-emacs-devel@m.gmane.org; Sun, 30 Oct 2011 13:54:02 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:37312) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RKZa3-0001kF-UM for emacs-devel@gnu.org; Sun, 30 Oct 2011 13:54:00 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RKZa2-0001wP-Bi for emacs-devel@gnu.org; Sun, 30 Oct 2011 13:53:59 -0400 Original-Received: from mtaout21.012.net.il ([80.179.55.169]:58463) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RKZa1-0001wB-To for emacs-devel@gnu.org; Sun, 30 Oct 2011 13:53:58 -0400 Original-Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0LTW009004B1KL00@a-mtaout21.012.net.il> for emacs-devel@gnu.org; Sun, 30 Oct 2011 19:53:56 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([77.124.128.216]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LTW009JX4DUJF30@a-mtaout21.012.net.il>; Sun, 30 Oct 2011 19:53:56 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 80.179.55.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:145802 Archived-At: > From: Andreas Schwab > Date: Sun, 30 Oct 2011 17:56:15 +0100 > Cc: Emacs Dev > > Alin Soare writes: > > > I wish to read the algorithm of gc, and I cannot. > > The Emacs gc is a simple mark and sweep collector. Right. Alin, you can start by reading the node "Garbage Collection" in the ELisp manual, and then proceed reading alloc.c, where you will see many functions named mark_SOMETHING and then gc_sweep that does the sweep stage. If you want more background before reading the ELisp manual, try googling "mark and sweep garbage collection".