From bf7360347ea3f7a24345004a6c2143d15d3d2e92 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 21 Mar 2008 06:36:07 -0400 Subject: Precompile pagespecs, about 10% overall speedup About 12% of ikiwiki runtime was spent in pagespec_match. It was evaling the same pagespec code over and over again. This changes pagespec_translate to return memoized, precompiled functions that can be called to match against a given pagespec. This also allows getting rid of the weird variable scoping trick that had to be in effect for pagespec_translate to be called -- the variables are now just fed into the function it returns. On my laptop, this drops build time for the docwiki from about 60 to 50 seconds. --- debian/changelog | 1 + 1 file changed, 1 insertion(+) (limited to 'debian/changelog') diff --git a/debian/changelog b/debian/changelog index c92cf86ed..90b13ed7d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -57,6 +57,7 @@ ikiwiki (2.41) UNRELEASED; urgency=low * Close meta tag for redir properly. * smiley: Detect smileys inside pre and code tags, and do not expand. * inline: Crazy optimisation to work around slow markdown. + * Precompile pagespecs, about 10% overall speedup. -- martin f. krafft Sun, 02 Mar 2008 17:46:38 +0100 -- cgit v1.2.3