From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nala Ginrut Newsgroups: gmane.lisp.guile.devel Subject: Whats' the proper senario of par-map? (Was Re: bug#13188: par-map causes VM stack overflow) Date: Thu, 28 Mar 2013 10:55:34 +0800 Organization: HFG Message-ID: <1364439334.2730.41.camel@Renee-desktop.suse> References: <1355559152.27310.5.camel@Renee-desktop.suse> <87y5d8rclr.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1364439347 4707 80.91.229.3 (28 Mar 2013 02:55:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 28 Mar 2013 02:55:47 +0000 (UTC) Cc: 13188-done@debbugs.gnu.org To: Ludovic =?ISO-8859-1?Q?Court=E8s?= , guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Thu Mar 28 03:56:13 2013 Return-path: Envelope-to: guile-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 1UL30b-0006Aw-AN for guile-devel@m.gmane.org; Thu, 28 Mar 2013 03:56:09 +0100 Original-Received: from localhost ([::1]:34551 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UL30C-0003hw-O0 for guile-devel@m.gmane.org; Wed, 27 Mar 2013 22:55:44 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:54763) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UL309-0003hg-Ho for guile-devel@gnu.org; Wed, 27 Mar 2013 22:55:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UL308-0007fT-LF for guile-devel@gnu.org; Wed, 27 Mar 2013 22:55:41 -0400 Original-Received: from mail-pa0-f43.google.com ([209.85.220.43]:46582) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UL307-0007f7-90; Wed, 27 Mar 2013 22:55:39 -0400 Original-Received: by mail-pa0-f43.google.com with SMTP id hz11so1280554pad.2 for ; Wed, 27 Mar 2013 19:55:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:subject:from:to:cc:date:in-reply-to :references:organization:content-type:x-mailer:mime-version :content-transfer-encoding; bh=/lysIWY6rOENsivLwZP/28gKKwNvOxpWt9visQk++y0=; b=Q7bfowKPsRvn4+grzcCx1iLcyT5yqba/IHH/rUmJdKNShto2OPbty+wWk0Btqxb0VI W7cc8c74UjpjcQa0GFAtmNni3mKYTNdQjUQgvKNRqaYIZoUo9mqOTmNArfCMF9fG2k1d M3ezeV930yDnT0VXbE7d0u1JKJna2tcATE1vI+TDUu8dUD0xunthNfJtJbsLKrmsUyFX 2fNxiP25qIaYFYxWTdITAof9yljTQgpG7NsgdN0fGTalnXH7ERk1nDz/LARqyLlymCU4 zbgI1LVLypKAzj/OORBNIs0XdsfM4SNh/TANRgmPrzJspdphLo+dT8RBJh/EO5LQiqA6 xnOA== X-Received: by 10.66.72.37 with SMTP id a5mr33169205pav.193.1364439338367; Wed, 27 Mar 2013 19:55:38 -0700 (PDT) Original-Received: from [147.2.147.112] ([61.14.130.226]) by mx.google.com with ESMTPS id hs8sm23615696pbc.27.2013.03.27.19.55.36 (version=SSLv3 cipher=RC4-SHA bits=128/128); Wed, 27 Mar 2013 19:55:37 -0700 (PDT) In-Reply-To: <87y5d8rclr.fsf@gnu.org> X-Mailer: Evolution 3.4.4 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.220.43 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:16043 Archived-At: On Wed, 2013-03-27 at 18:12 +0100, Ludovic Courtès wrote: > Hi, > > Nala Ginrut skribis: > > > scheme@(guile-user)> (par-map 1+ (iota 10000)) > > While executing meta-command: > > ERROR: Throw to key `vm-error' with args `(vm-run "VM: Stack > > overflow" ())'. > > Commit 8a177d3 fixes this. I added a paragraph in the documentation > that explains what happens: delimited continuations to the rescue once > again! ;-) > > Comments welcome. > oh~I love delimited continuations! But I'm still puzzled with the performance of par-map: --------------------cut------------------- scheme@(guile-user)> ,time (define a (map (lambda (x) (expt x 5)) (iota 10000))) ;; 0.008019s real time, 0.007979s run time. 0.000000s spent in GC. scheme@(guile-user)> ,time (define a (par-map (lambda (x) (expt x 5)) (iota 10000))) ;; 6.596471s real time, 6.579375s run time. 1.513880s spent in GC. --------------------end------------------- So my question is, what's the proper scenario to use par-map? > Ludo’.