Skip to content

Optimize target properties processing at generation step

Marc Chevrier requested to merge marc.chevrier/cmake:release-bugfixes into master

This optimization is a partial answer to performance regression introduced in version 3.13.

The goal is to avoid to create instances of classes cmGeneratorExpression and cmCompileGeneratorExpression which are costly (especially cmCompileGeneratorExpression).

To achieve that, because property values, in file cmGeneratorTarget.cxx, are managed through class cmGeneratorTarget::TargetPropertyEntry, two different sub-classes are used to implement common interface defined in the root class: one for generator expression (TargetPropertyEntryGenex), one for raw strings (TargetPropertyEntryString).

And instances of these sub-classes are created through function CreateTargetPropertyEntry which select the right class depending of the value of the property: genex or raw string.

Issue: #18965 (closed)
Topic-rename: optimize-properties-processing

Edited by Brad King

Merge request reports