summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/runqueue.py
AgeCommit message (Collapse)Author
2021-05-04bitbake: runqueue: Fix deferred task issuesRichard Purdie
In a multiconfig situation there are circumstances where firstly, tasks are deferred when they shouldn't be, then later, tasks can end up as both covered and not covered. This patch fixes two related issues. Firstly, the stamp validity checking is done up front in the build and not reevaulated. When rebuilding the deferred task list after scenequeue hash change updates, we need therefore need to check if a task was in notcovered *or* covered when deciding to defer it. This avoids strange logs like: NOTE: Running setscene task X of Y (mc:initrfs_guest:/A/alsa-state.bb:do_deploy_source_date_epoch_setscene) NOTE: Deferring mc:initrfs_guest:/A/alsa-state.bb:do_deploy_source_date_epoch after mc:host:/A/alsa-state.bb:do_deploy_source_date_epoch where tasks have run but are then deferred. Since we're recalculating the whole list, we also need to clear it before iterating to rebuild it. By ensuring covered tasks aren't added to the deferred queue, the covered + notcovered issue should also be avoided. in the task deadlock forcing code. [YOCTO #14342] (Bitbake rev: 32183076cb54f6d247471429cfd99491e41a1cab) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 3c8717fb9ee1114dd80fc1ad22ee6c9e312bdac7) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2021-03-24bitbake: runqueue: Add setscene task overlap sanity checkRichard Purdie
We've seen hard to debug issues where a task ends up in both the covered and notcovered list. Add a sanity check to ensure if this happens in future, we see it in the logs. (Bitbake rev: 947c2ad65e4c59d01c603f767f11f9aa86b69264) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 6e001410854792f9bb66a0409a2ac176171b0507) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2021-03-24bitbake: runqueue: Fix task execution corruption issueRichard Purdie
We've seen occasional issues where linux-yocto:do_compile_kernelmodules would run without do_shared_workdir running before it. do_shared_workdir is an setscene task but never has an sstate object generated so it will always rerun. This should not happen since compile_kernemodules should only execute if a setscene that depends on it didn't run and that should trigger do_shared_workdir not to be marked as covered. The issue is that build-appliance-image:do_package is one of the tasks which covers linux-yocto:do_compile_kernelmodules but it is also a noexec task and has a dependecy on pseudo-native:do_populate_sysroot. In the problem case, pseudo-native:do_populate_sysroot is unavailable but marked as covered since it is noexec. The "harddeps" code then also marks it as notcovered. No task should ever be both covered and notcovered and this is where the problems come from. The solution is for the harddeps code only to to fail tasks if they've not already been handled in some way. The code is assuming code couldn't have handled revdeps at this point but we now have clear evidence they can. (Bitbake rev: 0a61f86a8da5356ce0d894ef2ffb96ac6a219db5) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit f66556bbb38449789ceea2fd105e9f68df7fb660) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-08-25bitbake: runqueue: Don't use sys.argvRichard Purdie
We should not be using sys.argv inside the server to decide which targets the user added on the commandline. There might not even be a commandline. Thankfully the targets variable is easily accessible in this context and contains this exact data we want. (Bitbake rev: 5b12bf30bccdd00262e74964223220c649040be4) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-08-25bitbake: build/msg: Cleanup verbose option handlingRichard Purdie
The levels of indirection to set these verbose logging options is rather crazy. This attempts to turn things into two specific options with much more specific meanings. For now its all still controlled by the commandline verbose option and should funciton as previously, with the addition that the BB_VERBOSE_LOGS option can now be task specific. (Bitbake rev: 423c046f2173aaff3072dc3d0882d01b8a0b0212) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-28bitbake: runqueue: Avoid unpickle errors in rare casesRichard Purdie
In rare cases the pickled data from a task contains "</event>" which causes backtrace. This can be reproduced with something like: do_unpack_prepend () { bb.warn("</event>") } There are several solutions but the easiest is to catch this exception and look for the next marker instead as this should be the only way such an unpickle error could occur. This fixes rare exceptions seen on the autobuilder. Also add in other potential exceptions listed in the pickle manual page so that better debug is obtained should there be an error in this code path in future. exitcode doesn't need the same handling since we control what is in that data field and it could never contain </exitcode> (Bitbake rev: 5ada512d6f9cbbdf1172ff7818117c38b12225ca) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-12bitbake: bitbake: siggen: Pass all data caches to hash functionsJoshua Watt
Passing all the data caches to the task hashing functions allows them to correctly account for mcdepends in task signatures. This allows tasks to be correctly re-run when a mcdepends changes. By default, the legacy behavior is maintained for derived signature generators by passing a special proxy object that can either be used to access all multiconfigs or the legacy behavior. If a derived signature generator is updated, it can set the supports_multiconfig_datacaces property to instruct bitbake it deals with multiconfigs properly. [YOCTO #13724] (Bitbake rev: 8ff9203de4fce9c104c2987d86980c9f34036b97) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-10bitbake: bitbake: command: Move split_mc_pn to runqueueJoshua Watt
All of the other multiconfig splitting functions are located in runqueue so move the function to split a pn/fn there also so that its easier to see them all together. Fixes a case where the findBestProvider() command wasn't working for multiconfig because it was looking for a prefix of "multiconfig:" instead of the newer "mc:" (Bitbake rev: 325827af66434affc2da460cc8b9a5c460e38056) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-06-10bitbake: bitbake: cooker: Split file collections per multiconfigJoshua Watt
Splits the cooker to track a collection per multiconfig instead of a single collection for all multiconfigs. Practically speaking, this allows each multiconfigs to each have different BBMASKs that apply to it instead of each one using the mask specified in the base configuration. (Bitbake rev: dd6d8eca2027f8d9be8a734a493227b440075e49) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-13bitbake: runqueue: Lower setscene complete logging levelJoshua Watt
Lowers the level of the log message when setscene tasks have completed. This message can occur multiple times when hash equivalence is enabled, since the runqueue switches between executing setscene tasks and normal tasks. Since this is primarily of use when debugging hash equivalence, use the hash equivalence logger at VERBOSE level. [YOCTO #13813] (Bitbake rev: 7dd5b3900622008ff34ec70d71c6e994f460a46f) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-13bitbake: runqueue/siggen: Lower hash equivalence loggingJoshua Watt
Lowers the level at which hash equivalence messages are logged so as to not annoy the majority of users. The autobuilder can use a custom logging configuration to log these to a file for debugging (see contrib/autobuilderlog.json) [YOCTO #13813] (Bitbake rev: 2ddb649ea31afe052f08e3969e36abf6fb515bc2) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-13bitbake: runqueue/siggen: Log hash equivalence with a different loggerJoshua Watt
Switches the hash equivalence logging to use a different logger so that it can be easily filtered out with python's structured logging. (Bitbake rev: 20bb29ef973e9c5483eb50a74550ea207637367b) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-13bitbake: lib/bb/msg: Use log level instead of debug countJoshua Watt
Passes around the actual logging level as the default log level variable instead of the debug count. This makes it easier to deal with logging levels since the conversion from debug count and verbose flag only has to occur once when logging is initialized and after that actual log levels can be used (Bitbake rev: 41bd155faf7f65cb0727fcce972715769b26ca89) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-03-07bitbake: runqueue: teach runonly/runall to accept "do_task" as well as "task"Chris Laplante
Previously --runonly=do_task would give a misleading error like: ERROR: Could not find any tasks with the tasknames ['do_task'] to run within the recipes of the taskgraphs of the targets... The problem is that BitBake tried to find "do_do_task". So teach it to only add the do_ prefix if it's not already there. (Bitbake rev: 694904bde980606dc67c201da61f4fb685679b17) Signed-off-by: Chris Laplante <chris.laplante@agilent.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-01-19bitbake: lib: remove unused importsFrazer Clews
removed unused imports which made the code harder to read, and slightly but less efficient (Bitbake rev: 4367692a932ac135c5aa4f9f2a4e4f0150f76697) Signed-off-by: Frazer Clews <frazer.clews@codethink.co.uk> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-01-13bitbake: runqueue: Use a set for the setscene tasks listRichard Purdie
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). (Bitbake rev: f5daef68703481a3c243dfecc7de404e6ebfdbb6) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-01-02bitbake: runqueue: Fix task dependency corner case in sanity testRichard Purdie
A corner case was identified where tasks with valid stamps from previous builds need to be accounted for in the new sanity test in the migration code. Add a variable to track such completed tasks to ensure the sanity test works correctly. (Bitbake rev: d517b1ef13ca7ab2fb4d761d3bd3b9fb7c591514) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-01-02bitbake: runqueue: Ensure task dependencies are run correctlyRichard Purdie
We've seen a number of mystery failures where task B would run despite task A, its dependency not having run. An example would be do_compile when do_unpack didn't run. This has been tracked down to this code block. In theory it shouldn't trigger however it can and has due to bugs elsewhere. When it does, it causes significant weird failures and possible build corruption. Change the code to abort the build. This avoids any chance of corruption and should ensure the issues get reported, putting an end to the weird build failures. There may be some cases where this triggers and it shouldn't, we'll work through those as they arise and are identified. (Bitbake rev: 7a92b7f58ab187eddfe550bd6fb687240c7b11bb) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2020-01-02bitbake: runqueue: Fix equiv hash handling build failuresRichard Purdie
Regardless of whether we remapped the hash on the server or not, we need to have bitbake work as if we did as we need to match how the stamp files look. This change resolves build failures where tasks were rerunning when they shouldn't. (Bitbake rev: 40928f6991436cf687821015324483b205abfcb1) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Only call into the migrations function if migrations activeRichard Purdie
This doesn't save much time but does make the profile counts for the function more accurate which is in itself useful. (Bitbake rev: d446fa89d206fbc6d098215163c968ea5a8cf4a9) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Optimise task filteringRichard Purdie
We were seeing this running thousands of times with hashequiv, do the filtering where it makes more sense and make it persist. (Bitbake rev: 2cfeb9998a8ad5b1dcda0bb4e192c5e4306dab17) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Optimise out pointless loop iterationRichard Purdie
(Bitbake rev: 105d1f0748edde7753a4063e6fdc758ffc8a8a9e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Optimise task migration code slightlyRichard Purdie
Move the calls to difference_update out a code level which improves efficiency significantly. Also further combine the outer loop for efficiency too. These two changes remove a bottleneck from the performance charts. (Bitbake rev: e28ec69356f1797de3e4e3fca0fef710bc4564de) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Fix sstate task iteration performanceRichard Purdie
Creating a new sorted list of sstate tasks each iteration through runqueue is extremely ineffecient and was compounded by the recent change from a list to set. Create one sorted list instead of recreating it each time. (Bitbake rev: de18824996841c3f35f54ff5ad12f94f6dc20d88) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: siggen: Split get_tashhash for performanceRichard Purdie
There are two operations happening in get_taskhash, the building of the underlying data and the calculation of the hash. Split these into two funtions since the preparation part doesn't need to rerun when unihash changes, only the calculation does. This split allows sigificant performance improvements for hashequiv in builds where many hashes are equivalent and many hashes are changing. (Bitbake rev: 6a32af2808d748819f4af55c443578c8a63062b3) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Fix task mismatch failures from incorrect logicRichard Purdie
The "no dependencies" task case was not being correctly considered in this code and seemed to be the cause of occasionaly task hash mismatch errors that were being seen as the dependencies were never accounted for properly. (Bitbake rev: 608b9f821539de813bfbd9e65950dbc56a274bc2) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-16bitbake: runqueue: Rework process_possible_migrations() to improve performanceRichard Purdie
The looping over multiple changed hashes causes many calls to get_taskhash and get_unihash which are potentially slow and then overwritten. Instead, batch up all the tasks which have changed unihashes and then do one big loop over the changed tasks rather than each in turn. This makes worlds of difference to the performance graphs and should speed up build where many tasks are being rehashed. (Bitbake rev: c9c68d898985cf0bec6fc95f54c151cc50255cac) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-12bitbake: runqueue: Batch scenequeue updatesJoshua Watt
Batch all updates to scenequeue data together in a single invocation instead of checking each task serially. This allows the checks for sstate object to happen in parallel, and also makes sure the log statement only happens once (per set of rehashes). (Bitbake rev: db033a8f8a276d864bdb2e1eef159ab5794a0658) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-04bitbake: runqueue: Add extra debugging when locked sigs mismatches occurRichard Purdie
(Bitbake rev: 3aad9978be2a40d4c535a5ae092f374ba2a5f627) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-12-04bitbake: runqueue/siggen: Allow handling of equivalent hashesRichard Purdie
Based on the hashserv's new ability to accept hash mappings, update runqueue to use this through a helper function in siggen. This addresses problems with meta-extsdk-toolchain and its dependency on gdb-cross which caused errors when building eSDK. See the previous commit for more details. (Bitbake rev: 39098b4ba2133f4d9229a0aa4fcf4c3e1291286a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-11-29bitbake: runqueue.py: not show warning for deferred multiconfig taskKai Kang
When follow the instructions of multiconfig from Yocto dev manual that set in core-image-sato recipe: do_image[mcdepends] = "multiconfig:x86:arm:core-image-minimal:do_rootfs" it show too many annoying warnings look like: | WARNING: Deferring mc:x86:virtual:native:/buildarea6/kkang/poky/meta/recipes-support/libxslt/libxslt_1.1.33.bb:do_populate_sysroot | after mc:arm: virtual:native:/buildarea6/kkang/poky/meta/recipes-support/libxslt/libxslt_1.1.33.bb:do_populate_sysroot Treat them as infomations rather than warnings. (Bitbake rev: 0fb4b5153237af4a13b2c65711ab798b0de06c2f) Signed-off-by: Kai Kang <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-11-25bitbake: runqueue: Ensure failed harddependencies in scenequeue are ↵Richard Purdie
accounted for in migrations Setscene hard dependencies were not being correctly handled during task migration. For example, do_package of recipe X might become valid due to hashequiv yet we're still rebuilding pseudo-native, a harddep of do_package. This would mean it would try to execute that setscene task despite pseudo not being present. Fix this by ignoring tasks with failed harddependencies. This does mean stlightly more rebuilds than is optimal but it avoids build crashes. Ultimately the new runqueue model can likely better handle these cases than the older codebase could but that is for another more invasive patch. (Bitbake rev: 0dc61e8b9964f7fe41d51b6a481ca7aeaacd8bce) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-11-22bitbake: runqueue: Fix hash equivalence duplicate tasks runningRichard Purdie
The key problem is that currently running setscene tasks are not accounted for when processing task migrations. This means can allow two of the same task to execute at the same time with unpredictable effects. This change allows us to stop doing that and refactor the code slightly to make it clearer that these conditions don't arrive even with deferred tasks. (Bitbake rev: ac1922d348613ca46a1047ad5ddf755eac16d568) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-11-07bitbake: runqueue: Improve sstate rehashing outputRichard Purdie
Bibake is currently too 'chatty' when hash equivalence is enabled. Fix this by only printing the log output if a rehash happens and it matches an sstate object. Also, pass a summary option to the hash checking function. This was already changed to a mechanism which allows addition of new parameters so this should be backwards and forwards compatible. (Bitbake rev: 0c4515603ad08775e3b0404cba5374367e49f236) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-30bitbake: runqueue: Small performance optimisationRichard Purdie
A minor performance optmisation to keep lists smaller when running large builds. We can do this since once a task has been built, we don't need to worry about it. This improves a major bottleneck that shows up on performance profile charts in dryruns. (Bitbake rev: cd6b89230823707c3c9bb9e6883bf5a971916581) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-30bitbake: runqueue: Save unihashes more frequentlyRichard Purdie
There are some runqueue code paths where the unihash cache would not be saved where for example only parsing or an occurred. Save the cache at the end of runqueue generation to ensure entries are cached. (Bitbake rev: 9eee0d36870c11dd303894a6151c33a83bd3a1bc) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-30bitbake: siggen/runqueue: Fix signature mismatch issuesRichard Purdie
We need to set the setscene tasklist before we call into the taskhash/unihash code else the behaviour is inconsistent. Avoid reporting hashes for non setscene tasks since we'd never query that. (Bitbake rev: 419a7840b8627278db694029c25df00214d01d96) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-30bitbake: runqueue: Change task migration behaviour for rerunning setscene tasksRichard Purdie
Currently runqueue will rerun setscene tasks multiple times as hashes change. This has caused numerous problems since a setscene task may become "unavailable" for some future signature combination and the code then can't easily "unskip" tasks its already passed into the execution queue. At least for now, only run setscene once and assume they're equivalent at that point. In practise that has been much more stable in testing. Tweak the test to match the change in behaviour. (Bitbake rev: 4205a3ef23834f317642bba155d67cd772176fb6) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-30bitbake: runqueue: Fix task migration problemsRichard Purdie
Tasks were not migrating consistently, particularly: * if a task was rehashed which had already run * if a task which was valid became invalid due to a rehash We need to always run the migration code for rehashed tasks and then reprocess them for hash validity. This means rearranging the code. It also means several tests are no longer correct and can't be written correctly to work on all possible workflows so those are removed. (Bitbake rev: 8443989ee41e9b162972935513e437b5c66ea74d) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-19bitbake: runqueue: validate_hashes(): currentcount should be a numberRobert Yang
According to sstate_checkhashes which is defined in sstate.bbclass, the currentcoun should be a number (0, not None). Fixed: $ bitbake base-files -Sprintdiff > bb.plain("Sstate summary: Wanted %d Found %d Missed %d Current %d (%d%% match, %d%% complete)" % (total, len(found), len(missed), currentcount, match, complete)) TypeError: %d format: a number is required, not NoneType (Bitbake rev: 45cb73e2846eaffe8964a573875f54808e8f3633) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-18bitbake: bitbake: Rework hash equivalenceJoshua Watt
Reworks the hash equivalence server to address performance issues that were encountered with the REST mechanism used previously, particularly during the heavy request load encountered during signature generation. Notable changes are: 1) The server protocol is no longer HTTP based. Instead, it uses a simpler JSON over a streaming protocol link. This protocol has much lower overhead than HTTP since it eliminates the HTTP headers. 2) The hash equivalence server can either bind to a TCP port, or a Unix domain socket. Unix domain sockets are more efficient for local communication, and so are preferred if the user enables hash equivalence only for the local build. The arguments to the 'bitbake-hashserve' command have been updated accordingly. 3) The value to which BB_HASHSERVE should be set to enable a local hash equivalence server is changed to "auto" instead of "localhost:0". The latter didn't make sense when the local server was using a Unix domain socket. 4) Clients are expected to keep a persistent connection to the server instead of creating a new connection each time a request is made for optimal performance. 5) Most of the client logic has been moved to the hashserve module in bitbake. This makes it easier to share the client code. 6) A new bitbake command has been added called 'bitbake-hashclient'. This command can be used to query a hash equivalence server, including fetching the statistics and running a performance stress test. 7) The table indexes in the SQLite database have been updated to optimize hash lookups. This change is backward compatible, as the database will delete the old indexes first if they exist. 8) The server has been reworked to use python async to maximize performance with persistently connected clients. This requires Python 3.5 or later. (Bitbake rev: 2124eec3a5830afe8e07ffb6f2a0df6a417ac973) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-09-16bitbake: runqueue/siggen: Optimise hash equiv queriesRichard Purdie
We only have hash equivalence for setscene tasks so only query the server for those, reducing the number of connections needed. (Bitbake rev: 22082c7b3ca0cffcedb7d1d8c6681d35286376db) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-28bitbake: bitbake: respect force flag in runall and runonlyJoshua Watt
Specifying the force flag will now cause runall and runonly to invalidate the tasks before running them. This allows a --runall or --runonly to force the tasks to run, even if they would have otherwise been skipped, e.g.: bitbake -f --runall fetch Will run all do_fetch tasks even if they wouldn't be necessary (for example, skipped by setscene) (Bitbake rev: 71e52d3822016027106f2a2e74b8dfdf20f5dc1e) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-21bitbake: runqueue: Optimise build_taskdepdata slightlyRichard Purdie
Rather than repeatedly calling mc_from_tid() do this in the parent, removing around a million function calls. Takes time spent in this function from 40s to 36s. (Bitbake rev: 28b3f0d8867804799420689c314ac4a8f01efb8c) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-21bitbake: runqueue: Further optimise holdoff tasksRichard Purdie
There are other data structures which can be reprocessed at the same time as holdoff_tasks, further improving build efficiency in various places. (Bitbake rev: 02090b3456b7a2de12e72dfeaabfd3b631609924) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-21bitbake: runqueue: Optimise holdoff task handlingRichard Purdie
We don't need to process the holdoff task list until we're executing tasks which saves some data manipulation, at the cost of some data structures not being correct at all times. This saves significant amounts of time in various profile charts of larger builds. (Bitbake rev: 270f076111b12eab358417b0c4cf9c70d7cc787a) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-21bitbake: runqueue: Small but critical fixRichard Purdie
We've observed do_package and do_package_setscene running in parallel. The reason is that holdoff_tasks wasn't getting updated. Looking at the code, it would seem the reason is that the task was in pending_migrations and hence changed wasn't set and holdoff_tasks wasn't updated. Fix this. It only affects builds with rehashing enabled. (Bitbake rev: e26e61e84575669bd223f6ab316798097ed95ec8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-16bitbake: runqueue: Ensure target_tids is filteredRichard Purdie
bitbake <target> --runonly=fetch failed as the target_tids list included entries which were no longer targeted task ids. Fix this. (Bitbake rev: 94e848ae6544e628a19cb97115279b0b1678967c) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-15bitbake: runqueue: Ensure data is handled correctlyRichard Purdie
This doesn't appear to have ill effects right now but there is a correctness issue which this so fix it. (Bitbake rev: a5e084a266f63c2fd370122327615e49beaeb94e) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-08-15bitbake: runqueue: Fix data corruption problemRichard Purdie
This was overwriting data in the parent which caused all kinds of odd/weird failures. (Bitbake rev: 4c5aeb424247a9d0c907524ffacd9c61fcdc0852) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>