[bitbake-devel] [1.44 4/4] runqueue: Use a set for the setscene tasks list

Armin Kuster akuster808 at gmail.com
Wed Jan 22 05:25:02 UTC 2020


From: Richard Purdie <richard.purdie at linuxfoundation.org>

This should give performance improvements to functions using this list of
tasks (sets are used for most of the other code for this reason, not sure
why this wasn't a set in the first place).

Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
(cherry picked from commit f5daef68703481a3c243dfecc7de404e6ebfdbb6)
Signed-off-by: Armin Kuster <akuster808 at gmail.com>
---
 lib/bb/runqueue.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/bb/runqueue.py b/lib/bb/runqueue.py
index 6e3a91b8..d7186e85 100644
--- a/lib/bb/runqueue.py
+++ b/lib/bb/runqueue.py
@@ -1124,14 +1124,14 @@ class RunQueueData:
         self.init_progress_reporter.next_stage()
 
         # Iterate over the task list looking for tasks with a 'setscene' function
-        self.runq_setscene_tids = []
+        self.runq_setscene_tids = set()
         if not self.cooker.configuration.nosetscene:
             for tid in self.runtaskentries:
                 (mc, fn, taskname, _) = split_tid_mcfn(tid)
                 setscenetid = tid + "_setscene"
                 if setscenetid not in taskData[mc].taskentries:
                     continue
-                self.runq_setscene_tids.append(tid)
+                self.runq_setscene_tids.add(tid)
 
         self.init_progress_reporter.next_stage()
 
-- 
2.17.1



More information about the bitbake-devel mailing list