summaryrefslogtreecommitdiffstats
path: root/meta/lib
diff options
context:
space:
mode:
authorMarkus Lehtonen <markus.lehtonen@linux.intel.com>2016-06-23 18:25:53 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-07-01 16:22:47 +0100
commitfe24b5a597ee723b917b392c7e1570e88c50991a (patch)
tree525832b953b089491dc6204538b1b33c68ad4b5c /meta/lib
parent0b2fae81fdb6dc7ce557707d3680334612c1c27b (diff)
downloadpoky-fe24b5a597ee723b917b392c7e1570e88c50991a.tar.gz
oeqa.buildperf: add test Test3
Re-implement "test3" from build-perf-test.sh which measures bitbake parsing time. (From OE-Core rev: 388c7160b90247df9c78d8803083821402c13af5) Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib')
-rw-r--r--meta/lib/oeqa/buildperf/basic_tests.py20
1 files changed, 20 insertions, 0 deletions
diff --git a/meta/lib/oeqa/buildperf/basic_tests.py b/meta/lib/oeqa/buildperf/basic_tests.py
index 9012a2df3e..4ebbb77574 100644
--- a/meta/lib/oeqa/buildperf/basic_tests.py
+++ b/meta/lib/oeqa/buildperf/basic_tests.py
@@ -83,3 +83,23 @@ class Test2(BuildPerfTest):
83 self.sync() 83 self.sync()
84 cmd = ['bitbake', self.build_target, '-c', 'rootfs'] 84 cmd = ['bitbake', self.build_target, '-c', 'rootfs']
85 self.measure_cmd_resources(cmd, 'do_rootfs', 'bitbake do_rootfs') 85 self.measure_cmd_resources(cmd, 'do_rootfs', 'bitbake do_rootfs')
86
87
88@perf_test_case
89class Test3(BuildPerfTest):
90 name = "test3"
91 description = "Parsing time metrics (bitbake -p)"
92
93 def _run(self):
94 # Drop all caches and parse
95 self.rm_cache()
96 self.force_rm(os.path.join(self.bb_vars['TMPDIR'], 'cache'))
97 self.measure_cmd_resources(['bitbake', '-p'], 'parse_1',
98 'bitbake -p (no caches)')
99 # Drop tmp/cache
100 self.force_rm(os.path.join(self.bb_vars['TMPDIR'], 'cache'))
101 self.measure_cmd_resources(['bitbake', '-p'], 'parse_2',
102 'bitbake -p (no tmp/cache)')
103 # Parse with fully cached data
104 self.measure_cmd_resources(['bitbake', '-p'], 'parse_3',
105 'bitbake -p (cached)')