From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thierry Banel Subject: Re: speeding up Babel Gnuplot Date: Mon, 02 Jan 2017 21:11:07 +0100 Message-ID: <586AB3DB.6070702@free.fr> References: <5864217C.7060001@free.fr> <586963CB.1000006@free.fr> <87d1g6qrqh.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:34441) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cO8wr-00016V-FQ for emacs-orgmode@gnu.org; Mon, 02 Jan 2017 15:11:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cO8wo-0005nw-Av for emacs-orgmode@gnu.org; Mon, 02 Jan 2017 15:11:13 -0500 Received: from smtp1-g21.free.fr ([212.27.42.1]:42750) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cO8wo-0005nh-2D for emacs-orgmode@gnu.org; Mon, 02 Jan 2017 15:11:10 -0500 Received: from [IPv6:2a01:e35:2e21:def0:5c6:c54e:521f:2c36] (unknown [IPv6:2a01:e35:2e21:def0:5c6:c54e:521f:2c36]) by smtp1-g21.free.fr (Postfix) with ESMTP id 23EB6B0058F for ; Mon, 2 Jan 2017 21:11:08 +0100 (CET) In-Reply-To: <87d1g6qrqh.fsf@nicolasgoaziou.fr> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: "emacs-orgmode@gnu.org >> Org Mode" Le 02/01/2017 00:34, Nicolas Goaziou a =E9crit : > Hello, > > Thierry Banel writes: > >> 1. Temporary generated twice >> Because org-babel-gnuplot-process-vars is called twice. >> >> There is no obvious fix. Here is a dirty patch. It caches the name of >> the temporary file in the 'param' list. > This may not be an issue if `orgtbl-to-generic' is sufficiently fast. I will look further into that. >> 2. Quadratic behavior >> The spot is at ox.el::5119(the lambda in org-export-table-row-number). >> >> This lambda is called a number of times equal to the square of thesize >> of the table being plotted. For a 2000 rows table, this is >> 2000x2000 =3D four millions times. The cache a few lines before does >> nothelp because each row is visited only once. > Fixed. Thank you. > > I also optimized a bit more `orgtbl-to-generic'. Hopefully, Babel > Gnuplot should be responsive again of large tables. > Great improvement! So,filling the org-export-table-row-numbercache at once was the way to go= . Thanks