diff options
author | Alexander Kanavin <alex.kanavin@gmail.com> | 2024-01-30 14:55:56 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-02-08 17:12:54 +0000 |
commit | a380d6d13702293df17699851ec25d13ac28cbfc (patch) | |
tree | 4c8fc7819b3b3c672c8687976a82e6eac17e0da2 /meta/lib/oeqa | |
parent | 5ae7c6268b48146a515970343b1c417a40c15968 (diff) | |
download | poky-a380d6d13702293df17699851ec25d13ac28cbfc.tar.gz |
selftest/SStateCacheManagement: pre-populate the cache
This is another source of the test slowness: for some configurations
(building x86 on x86) the cache items are pre-populated in other
builds. For others (building 32 bit x86 on arm), they're not. Without
this step, the test would build them, write them to a private
sstate, and then throw it away.
The code is un-pythonic: it follows the style of the rest of the test,
and fixing that is perhaps for some other time.
With these two changes the notoriously slow test_sstate_cache_management_script_using_machine
takes just under 6 minutes, on an arm worker:
https://autobuilder.yoctoproject.org/typhoon/#/builders/127/builds/2820/steps/13/logs/stdio
(From OE-Core rev: b685c955289bf4d7d70bd0f4c1530b2bf13a30a6)
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa')
-rw-r--r-- | meta/lib/oeqa/selftest/cases/sstatetests.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/cases/sstatetests.py b/meta/lib/oeqa/selftest/cases/sstatetests.py index f2adf73263..56dfcdb0f3 100644 --- a/meta/lib/oeqa/selftest/cases/sstatetests.py +++ b/meta/lib/oeqa/selftest/cases/sstatetests.py | |||
@@ -268,6 +268,14 @@ class SStateCacheManagement(SStateBase): | |||
268 | self.assertTrue(global_config) | 268 | self.assertTrue(global_config) |
269 | self.assertTrue(target_config) | 269 | self.assertTrue(target_config) |
270 | self.assertTrue(len(global_config) == len(target_config), msg='Lists global_config and target_config should have the same number of elements') | 270 | self.assertTrue(len(global_config) == len(target_config), msg='Lists global_config and target_config should have the same number of elements') |
271 | |||
272 | for idx in range(len(target_config)): | ||
273 | self.append_config(global_config[idx]) | ||
274 | self.append_recipeinc(target, target_config[idx]) | ||
275 | bitbake(target) | ||
276 | self.remove_config(global_config[idx]) | ||
277 | self.remove_recipeinc(target, target_config[idx]) | ||
278 | |||
271 | self.config_sstate(temp_sstate_location=True, add_local_mirrors=[self.sstate_path]) | 279 | self.config_sstate(temp_sstate_location=True, add_local_mirrors=[self.sstate_path]) |
272 | 280 | ||
273 | # For now this only checks if random sstate tasks are handled correctly as a group. | 281 | # For now this only checks if random sstate tasks are handled correctly as a group. |