aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/corelib/buildgraph/artifact.h
Commit message (Collapse)AuthorAgeFilesLines
* Apply fix-its for the missing override keywordIvan Komissarov2019-05-031-1/+1
| | | | | | | | Missing override is a warning in clang Change-Id: I90b899df37e690aebb942bffc65db54d9aa4050f Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Use QStringLiteral more where it is possibleDenis Shienkov2019-02-251-9/+9
| | | | | | Change-Id: I7419cc3fbc1e8776de3943852dcedab4c95d1c32 Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Fix potential dereference of Artifact null pointerChristian Kandeler2018-09-051-1/+1
| | | | | | | This amends 10b8b75f42. Change-Id: I50dcfb8a79cd3a1a7c7baf4b34d15dda7035695a Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* RulesApplicator: Fix assertionChristian Kandeler2018-07-181-0/+2
| | | | | | | | | | | There can be input artifacts that are produced by a rule that is not connected to the current rule. This happens if at least one of the outputs of the rule that produces the input matches the excluded inputs of the current rule, in which case there is no connection between the rules. Change-Id: If51344e95e971ae89745ce7c20c2623774af42ae Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Remember which module properties were set explicitly on an artifactChristian Kandeler2018-07-051-0/+7
| | | | | | | | | ... and consider these when updating the properties of generated artifacts during the change tracking process. This amends 768fc9c72e. Change-Id: Ifd3f6342fec8313b8cdd2e611734fc52a3810ae8 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Do not reset the product build data due to source file metadata changesChristian Kandeler2018-07-051-0/+5
| | | | | | | | | | | | | | | | It is not necessary to throw away and recreate all the product's artifacts and rule nodes if a source file's tags or properties change. Instead, just copy the new data into the corresponding Artifact object. As a necessary side effect, we also handle changes to the product- level module properties and to "fileTagsFilter groups" in a more fine- grained manner by resetting the properties and file tags of the product's Artifact objects that represent generated artifacts. This is part of a long-term effort to eliminate the build graph's "shadow structure" aka RescuableArtifactData. The next step will deal with added and removed source files. Change-Id: I054fa18d7920ea5c429c92bfca1c12e34192211e Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Store the "out of date" flag per transformer rather than per artifactChristian Kandeler2018-06-291-2/+0
| | | | | | | That's a better fit. Change-Id: I3eff4ce461342b2966196da4e9aeff35544a38c4 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Mark parent artifacts explicitly as out of dateChristian Kandeler2018-05-181-0/+2
| | | | | | | | | | ... after a transformer finishes. This makes our "out of date" check independent of the local clock resolution for generated artifacts that do not have source artifacts as children. Change-Id: If3d47f1fd859c30846806fabaddf3b47a840a6d3 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Get rid of redundancies between load() and store() methodsChristian Kandeler2018-02-161-1/+1
| | | | | | | | | | It's silly that we have to mention each serializable data member in both the load and the store methods. Instead, whenever possible, forward these methods to a template that calls the right function in the persistence backend based on its parameter. Change-Id: I00e2dee8cdf55405f447cee27190bc97df8673e3 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Get rid of all remaining dynamic_castsChristian Kandeler2017-12-071-0/+6
| | | | | | | This speeds up rule execution by another 2%. Change-Id: If819144f2c01bd243ec98f7a6d050bc5faa2b02c Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Get rid of the PersistentObject classChristian Kandeler2017-12-061-1/+5
| | | | | | | | | | | | Our serialization requirements are fully served by the template mechanism; there is no need to put an inheritance-based approach on top of it. Now there is no more virtual inheritance, which allowed us to get rid of one more dynamic_cast. According to our benchmarker, build graph loading has become about 3% faster. Change-Id: If2f5080f74a0ef972a575ac2798f9d94a7f3b519 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix inconsistent-missing-override warningsJake Petroules2017-11-301-6/+6
| | | | | | | Amends c03f79f Change-Id: I3dac635605170032d5c0e7c0c35e5ed3e60928bb Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Remove as many dynamic_casts as possibleChristian Kandeler2017-11-301-0/+1
| | | | | | | | According to our benchmarker, this speeds up rule execution by three per cent. Change-Id: Iaf146ba6073b897d19e0fe470d7b0dc4a04d264c Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Enable modules to declare target artifactsChristian Kandeler2017-11-071-0/+3
| | | | | | | | | | | | | Such artifacts appear to rules just like target artifacts of products. This functionality will be useful for auto-generating qbs modules from products. [ChangeLog] Modules can now declare target artifacts using the new filesAreTargets property of the Group item. Task-number: QBS-882 Change-Id: I3bba000be9a1057d9fef01e5576363719ff1f244 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Move the buildgraph, language and tools tests into the proper locationsJake Petroules2017-06-221-1/+1
| | | | | | | Also export necessary symbols that they need. Change-Id: I3023893a3da82cf0d86b0d08df38943db867cf3a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Use a sorted vector rather than QSet or std::setChristian Kandeler2017-01-051-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | ========== 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>
* Change style of #includes of Qt headersJake Petroules2017-01-041-2/+2
| | | | | | | | | | | | | | | | By using q<lowercase>.h headers, we become more bootstrap-friendly, as no full syncqt is required any more. In the same go, prefix all includes with the module name. This helps grep-based analysis of which parts of Qt are used and where. It's also consistent with Qt's public headers (where syncqt enforces the style). Testdata and examples are excluded from the change, as they are not relevant for bootstrapping. Change-Id: I9539b1d795e87fca6e5fc6c91acbb775b79208d9 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Use a QVector instead of a QSet for storing file dependenciesChristian Kandeler2016-11-281-1/+1
| | | | | | | | | | | | | | | The latter uses an excessive amount of memory. ========== Performance data for Rule Execution ========== Old instruction count: 3598974492 New instruction count: 3761081266 Relative change: +4 % Old peak memory usage: 22644176 Bytes New peak memory usage: 18111064 Bytes Relative change: -21 % Change-Id: Ie87514a2622a32307d061b48c92b4145c1b477f1 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Update license headersIikka Eklund2016-08-291-14/+23
| | | | | | | | | | Patch-set 1 includes *.h Every source file needs to have up-to-date license headers in order to pass ci. Change-Id: Ib6cf3ac47dfba6dff262fded44bc952aef3bda8b Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Merge remote-tracking branch 'origin/1.5'Joerg Bornemann2016-06-081-1/+1
|\ | | | | | | | | | | | | | | Conflicts: doc/reference/items/transformer.qdoc share/qbs/modules/cpp/GenericGCC.qbs Change-Id: I45560834560019b18274c373c45651eb8aadd206
| * Replace 'the Qt build suite' with 'Qbs' in copyright notices.Jake Petroules2016-06-061-1/+1
| | | | | | | | | | | | Change-Id: I885d94bb14b325dc36767a840ebdb0be1fb59dd2 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Avoid copies of node containersJoerg Bornemann2016-05-191-2/+2
|/ | | | | | | | | We've used ArtifactSet::fromNodeSet to iterate over all artifacts in a node container. This creates a container copy. Use a filtering iterator instead. Change-Id: I368d3e4b1a259634c8cd5dbd53f372577b3ed14b Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* update license headersJoerg Bornemann2015-03-021-2/+2
| | | | | Change-Id: I36d825db3a5ef32c162c3063aab1e8a1f2696f4f Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* Update LicenseEike Ziller2015-01-261-6/+6
| | | | | Change-Id: I092fca9f950de1ba38826c33b155f86feae2770b Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* License update.Eike Ziller2014-10-161-7/+8
| | | | | | | Add LGPLv3 option. Change-Id: I8a63ad5e46a2701032b2103f791df4dec5b707e8 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* add getter/setters for Artifact::fileTagsJoerg Bornemann2014-07-311-1/+7
| | | | | | | | | The setters take care of keeping the product's artifact-by-filetags hash up to date. Before, one had to set up the artifact's file tags before insertArtifactToProduct was called. Otherwise the hash didn't get updated. Change-Id: Ibb530d2c992d72c0a99152009b4e6eecbf770098 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
* support transformers with an unknown number of outputsJoerg Bornemann2014-02-131-22/+15
| | | | | | | | | | | | | | | | To support different types of nodes in the build graph, we introduce the base class BuildGraphNode. Artifact now derives from BuildGraphNode. A RuleNode class is introduced that represents a rule in the build graph. Rules are applied in the build phase and not in a pre-build phase anymore. The handling of moc has been revisited. The fixed automoc pre-build phase is no more. This is the squashed merge of a feature branch. Task-number: QBS-370 Change-Id: If27cdc51cba8c9542e4282c2caa456faa723aeff Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
* rename ArtifactList to ArtifactSetJoerg Bornemann2014-01-161-4/+4
| | | | | | | Now the name reflects reality. Change-Id: I3997b99de86819c973434240103d25d6915d838b Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
* Move Qt profile setup into a dedicated library.Christian Kandeler2014-01-101-0/+135
Otherwise all changes to the implementation will have to be duplicated in IDEs. Change-Id: I61e6d4fa1ee9b724eb5d9de9f233dc915a6c8bc3 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>