From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tom Tromey Newsgroups: gmane.emacs.devel Subject: Re: [0/10] threads for emacs Date: Mon, 13 Aug 2012 08:39:59 -0600 Message-ID: <87has67t4w.fsf@fleche.redhat.com> References: <87zk63eu2p.fsf@fleche.redhat.com> <5027E83F.7080703@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1344868815 18656 80.91.229.3 (13 Aug 2012 14:40:15 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 13 Aug 2012 14:40:15 +0000 (UTC) Cc: Emacs discussions To: Dmitry Antipov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Aug 13 16:40:15 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1T0voU-0008AU-NF for ged-emacs-devel@m.gmane.org; Mon, 13 Aug 2012 16:40:14 +0200 Original-Received: from localhost ([::1]:55493 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T0voT-0003B8-Mx for ged-emacs-devel@m.gmane.org; Mon, 13 Aug 2012 10:40:13 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:45714) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T0voM-00035k-Ij for emacs-devel@gnu.org; Mon, 13 Aug 2012 10:40:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T0voJ-00049k-0d for emacs-devel@gnu.org; Mon, 13 Aug 2012 10:40:06 -0400 Original-Received: from mx1.redhat.com ([209.132.183.28]:8850) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T0voI-00048J-Oe for emacs-devel@gnu.org; Mon, 13 Aug 2012 10:40:02 -0400 Original-Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q7DEe1rI003738 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 13 Aug 2012 10:40:01 -0400 Original-Received: from barimba (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q7DEdxMf008609 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Mon, 13 Aug 2012 10:40:00 -0400 X-Attribution: Tom In-Reply-To: <5027E83F.7080703@yandex.ru> (Dmitry Antipov's message of "Sun, 12 Aug 2012 21:30:39 +0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.132.183.28 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:152486 Archived-At: >>>>> "Dmitry" == Dmitry Antipov writes: Dmitry> I'm trying to improve GC (by making it generational at first), and it's Dmitry> almost obvious that full-featured multithreading requires substantial Dmitry> support from GC; our final goal might be a fully parallel GC performed Dmitry> simultaneously by the all threads, or special GC thread(s) to perform Dmitry> an incremental collection, or whatever else. Do you have any thoughts Dmitry> about how the GC should be improved for the sake of threading support? The current patch series isn't too interesting from the GC point of view, I think, because only one thread runs Lisp at a time. It would be interesting to run the GC concurrently with Lisp. I think the hard part here is ensuring that all GC-visible changes occur atomically. E.g., writing an untagged pointer to the heap would cause problems. This may already work "well enough". It is hard to know for sure though. I think some static analysis would perhaps help. Tom