diff options
-rw-r--r-- | bitbake/lib/bb/cooker.py | 3 | ||||
-rw-r--r-- | bitbake/lib/bb/siggen.py | 11 |
2 files changed, 13 insertions, 1 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index 77d18a5d0c..cfac91bae5 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py | |||
@@ -1934,7 +1934,8 @@ class Parser(multiprocessing.Process): | |||
1934 | except IndexError: | 1934 | except IndexError: |
1935 | break | 1935 | break |
1936 | result = self.parse(*job) | 1936 | result = self.parse(*job) |
1937 | 1937 | # Clear the siggen cache after parsing to control memory usage, its huge | |
1938 | bb.parse.siggen.postparsing_clean_cache() | ||
1938 | try: | 1939 | try: |
1939 | self.results.put(result, timeout=0.25) | 1940 | self.results.put(result, timeout=0.25) |
1940 | except queue.Full: | 1941 | except queue.Full: |
diff --git a/bitbake/lib/bb/siggen.py b/bitbake/lib/bb/siggen.py index 3e2a85fc8c..9c299d45e3 100644 --- a/bitbake/lib/bb/siggen.py +++ b/bitbake/lib/bb/siggen.py | |||
@@ -48,6 +48,9 @@ class SignatureGenerator(object): | |||
48 | def get_unihash(self, task): | 48 | def get_unihash(self, task): |
49 | return self.taskhash[task] | 49 | return self.taskhash[task] |
50 | 50 | ||
51 | def postparsing_clean_cache(self): | ||
52 | return | ||
53 | |||
51 | def get_taskhash(self, fn, task, deps, dataCache): | 54 | def get_taskhash(self, fn, task, deps, dataCache): |
52 | return "0" | 55 | return "0" |
53 | 56 | ||
@@ -152,6 +155,14 @@ class SignatureGeneratorBasic(SignatureGenerator): | |||
152 | for task in taskdeps: | 155 | for task in taskdeps: |
153 | d.setVar("BB_BASEHASH_task-%s" % task, self.basehash[fn + "." + task]) | 156 | d.setVar("BB_BASEHASH_task-%s" % task, self.basehash[fn + "." + task]) |
154 | 157 | ||
158 | def postparsing_clean_cache(self): | ||
159 | # | ||
160 | # After parsing we can remove some things from memory to reduce our memory footprint | ||
161 | # | ||
162 | self.gendeps = {} | ||
163 | self.lookupcache = {} | ||
164 | self.taskdeps = {} | ||
165 | |||
155 | def rundep_check(self, fn, recipename, task, dep, depname, dataCache): | 166 | def rundep_check(self, fn, recipename, task, dep, depname, dataCache): |
156 | # Return True if we should keep the dependency, False to drop it | 167 | # Return True if we should keep the dependency, False to drop it |
157 | # We only manipulate the dependencies for packages not in the whitelist | 168 | # We only manipulate the dependencies for packages not in the whitelist |