aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/corelib/buildgraph/rulegraph.cpp
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@qt.io>2016-12-23 21:06:24 +0100
committerChristian Kandeler <christian.kandeler@qt.io>2017-01-05 09:12:13 +0000
commit88f6c8aefc377b3b0b121bf27c6b33760ca157a8 (patch)
tree71404ce0c12ca086ffaf96e4df36dd032a03e256 /src/lib/corelib/buildgraph/rulegraph.cpp
parent36e736977e93fcc5d4165cd25b64e9ff20c820ac (diff)
Use a sorted vector rather than QSet or std::set
========== Performance data for Resolving ========== Old instruction count: 2324724447 New instruction count: 2317712921 Relative change: -1 % Old peak memory usage: 21411584 Bytes New peak memory usage: 21070552 Bytes Relative change: -2 % ========== Performance data for Rule Execution ========== Old instruction count: 4231322611 New instruction count: 4246208129 Relative change: +0 % Old peak memory usage: 19239000 Bytes New peak memory usage: 18181072 Bytes Relative change: -6 % ========== Performance data for Null Build ========== Old instruction count: 542161499 New instruction count: 505511534 Relative change: -7 % Old peak memory usage: 13599040 Bytes New peak memory usage: 11892952 Bytes Relative change: -13 % Change-Id: I36b3dbd3fd2a4bc7503ee7779d31bd0217000785 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'src/lib/corelib/buildgraph/rulegraph.cpp')
-rw-r--r--src/lib/corelib/buildgraph/rulegraph.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/corelib/buildgraph/rulegraph.cpp b/src/lib/corelib/buildgraph/rulegraph.cpp
index 7e13b8ef0..5d206876f 100644
--- a/src/lib/corelib/buildgraph/rulegraph.cpp
+++ b/src/lib/corelib/buildgraph/rulegraph.cpp
@@ -49,7 +49,7 @@ RuleGraph::RuleGraph()
{
}
-void RuleGraph::build(const QSet<RulePtr> &rules, const FileTags &productFileTags)
+void RuleGraph::build(const Set<RulePtr> &rules, const FileTags &productFileTags)
{
QMap<FileTag, QList<const Rule *> > inputFileTagToRule;
m_rules.reserve(rules.count());
@@ -69,7 +69,7 @@ void RuleGraph::build(const QSet<RulePtr> &rules, const FileTags &productFileTag
foreach (const FileTag &fileTag, inFileTags) {
inputFileTagToRule[fileTag].append(rule.data());
foreach (const Rule * const producingRule, m_outputFileTagToRule.value(fileTag)) {
- if (!producingRule->collectedOutputFileTags().matches(
+ if (!producingRule->collectedOutputFileTags().intersects(
rule->excludedAuxiliaryInputs)) {
connect(rule.data(), producingRule);
}
@@ -98,7 +98,7 @@ void RuleGraph::dump() const
{
QByteArray indent;
printf("---rule graph dump:\n");
- QSet<int> rootRules;
+ Set<int> rootRules;
foreach (const RuleConstPtr &rule, m_rules)
if (m_parents[rule->ruleGraphId].isEmpty())
rootRules += rule->ruleGraphId;