From 2ede341d59b4ab259caf808dfa65c0ac380ba347 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 8 Mar 2022 10:57:52 +0200 Subject: Improve performance of update during match for multiple targets --- libbuild2/algorithm.hxx | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'libbuild2/algorithm.hxx') diff --git a/libbuild2/algorithm.hxx b/libbuild2/algorithm.hxx index c30680a..788138b 100644 --- a/libbuild2/algorithm.hxx +++ b/libbuild2/algorithm.hxx @@ -609,6 +609,19 @@ namespace build2 action, const target&, timestamp = timestamp_unknown); + // As above, but update all the targets in prerequisite_targets that have + // the specified mask in prerequisite_target::include. Return true if any of + // them have changed. + // + // Note that this function spoils prerequisite_target::data (which is used + // for temporary storage). But it resets data to 0 once done. + // + LIBBUILD2_SYMEXPORT bool + update_during_match (tracer&, + action, + prerequisite_targets&, + uintptr_t mask); + // The default prerequisite execute implementation. Call execute_async() on // each non-ignored (non-NULL) prerequisite target in a loop and then wait // for their completion. Return target_state::changed if any of them were -- cgit v1.1