From: Catalin Marinas Date: Thu, 18 Aug 2005 12:46:20 +0000 (+0100) Subject: Optimise the Commit objects creation X-Git-Tag: v0.6~6 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/stgit/commitdiff_plain/8e29bcd2fd67066143b88de8829130c6af043e2f?hp=8e29bcd2fd67066143b88de8829130c6af043e2f Optimise the Commit objects creation The Commit objects are used for commands like 'series' to check whether a patch is empty or not. Since the bottom of a patch is usually the same as the top of the previous one, it makes sense to cache the Commit objects and reduce their creation (and git-cat-file calls) to half. This patch adds a Commit objects factory which caches the results. Signed-off-by: Catalin Marinas ---