From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dan.rpsys.net (5751f4a1.skybroadband.com [87.81.244.161]) by mail.openembedded.org (Postfix) with ESMTP id 06312762B3 for ; Wed, 11 Nov 2015 16:56:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by dan.rpsys.net (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id tABGumkk014444 for ; Wed, 11 Nov 2015 16:56:48 GMT Received: from dan.rpsys.net ([127.0.0.1]) by localhost (dan.rpsys.net [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 76-OTu7r_YsZ for ; Wed, 11 Nov 2015 16:56:48 +0000 (GMT) Received: from [192.168.3.10] ([192.168.3.10]) (authenticated bits=0) by dan.rpsys.net (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id tABGuXXh014439 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT) for ; Wed, 11 Nov 2015 16:56:46 GMT Message-ID: <1447260992.3559.244.camel@linuxfoundation.org> From: Richard Purdie To: bitbake-devel Date: Wed, 11 Nov 2015 08:56:32 -0800 X-Mailer: Evolution 3.12.11-0ubuntu3 Mime-Version: 1.0 Subject: [PATCH] codeparser: Only load the codeparser chace once X-BeenThere: bitbake-devel@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussion that advance bitbake development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Nov 2015 16:56:52 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit The server state gets reset multiple times during startup and currently we reload the codeparser cache each time. This is pointless and causes unnecessary interaction time with bitbake. Signed-off-by: Richard Purdie diff --git a/bitbake/lib/bb/codeparser.py b/bitbake/lib/bb/codeparser.py index 82a3af4..6c9a42d 100644 --- a/bitbake/lib/bb/codeparser.py +++ b/bitbake/lib/bb/codeparser.py @@ -144,6 +144,10 @@ class CodeParserCache(MultiProcessCache): return cacheline def init_cache(self, d): + # Check if we already have the caches + if self.pythoncache: + return + MultiProcessCache.init_cache(self, d) # cachedata gets re-assigned in the parent