From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Neil Jerram Newsgroups: gmane.lisp.guile.devel Subject: Re: goops and memoization Date: 21 Nov 2002 20:31:48 +0000 Sender: guile-devel-admin@gnu.org Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1037912780 32458 80.91.224.249 (21 Nov 2002 21:06:20 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 21 Nov 2002 21:06:20 +0000 (UTC) Cc: Dirk Herrmann , guile-devel@gnu.org Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18EyWg-0008RM-00 for ; Thu, 21 Nov 2002 22:06:19 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 18EyVm-0000gZ-00; Thu, 21 Nov 2002 16:05:22 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 18EyUU-0008PH-00 for guile-devel@gnu.org; Thu, 21 Nov 2002 16:04:02 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 18EyUO-0008Nm-00 for guile-devel@gnu.org; Thu, 21 Nov 2002 16:04:00 -0500 Original-Received: from mail.uklinux.net ([80.84.72.21] helo=s1.uklinux.net) by monty-python.gnu.org with esmtp (Exim 4.10) id 18EyUN-0008LS-00 for guile-devel@gnu.org; Thu, 21 Nov 2002 16:03:55 -0500 Original-Received: from laruns.ossau.uklinux.net (bts-0886.dialup.zetnet.co.uk [194.247.51.118]) by s1.uklinux.net (8.11.6/8.11.6) with ESMTP id gALL3pS07759; Thu, 21 Nov 2002 21:03:51 GMT Original-Received: from laruns.ossau.uklinux.net.ossau.uklinux.net (localhost [127.0.0.1]) by laruns.ossau.uklinux.net (Postfix on SuSE Linux 7.2 (i386)) with ESMTP id BB876DC12B; Thu, 21 Nov 2002 20:31:48 +0000 (GMT) Original-To: djurfeldt@nada.kth.se In-Reply-To: Original-Lines: 43 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 Errors-To: guile-devel-admin@gnu.org X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Developers list for Guile, the GNU extensibility library List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.lisp.guile.devel:1735 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.devel:1735 >>>>> "Mikael" == Mikael Djurfeldt writes: Mikael> I added GOOPS to Guile because I needed an object system Mikael> in my neural simulator. ... later I judged it would serve Mikael> people better to add the code to the Guile source tree Mikael> than letting people wait infinitely until my rewrite would Mikael> get high enough priority. There's no question in my mind that you did the right thing here. Mikael> While there are "dark corners" in GOOPS I still dare to Mikael> claim that it works on sound principles, works reliably Mikael> and is probably one of the most efficient Scheme object Mikael> systems. Benchmarks show that GOOPS method dispatch is Mikael> negligible and a GOOPS generic function nearly as Mikael> efficient as an ordinary closure. Are those benchmarks available? If I do change the code, it would be good to check that the changes don't hurt performance. Mikael> To get GOOPS fast, we cache the results of this involved Mikael> process in a "method cache" in the generic function. Next Mikael> time a GF is applied to the same set of argument types, ... and if no new methods have been added in the meantime ... Mikael> the evaluator just makes a quick lookup in the cache and Mikael> can start to evaluate the method body without delay. The Mikael> format of the method cache is described in Mikael> oop/goops/dispatch.scm. Mikael> Currently, compile-method only makes sure the method has a Mikael> local next-method binding (specific to this method cache Mikael> entry) if that is needed. However, there are plans to let Mikael> it make powerful optimizations of the code, with great Mikael> potential of reducing overhead. Do you mean IOR ? If so, couldn't most IOR optimizations be made when the method is first defined? Thanks for the explanations. Neil _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://mail.gnu.org/mailman/listinfo/guile-devel