make ProFileOption persist during the scan of an entire project

there is no point in throwing away and re-recreating invariant data over
and over ...

shaves off ~15% of the load time of Qt 4.6.
This commit is contained in:
Oswald Buddenhagen
2009-12-07 20:49:39 +01:00
parent 0682dae77c
commit ef660880ad
11 changed files with 67 additions and 62 deletions

View File

@@ -288,8 +288,7 @@ void S60DeviceRunConfiguration::updateTarget()
emit targetInformationChanged();
return;
}
QtVersion *qtVersion = qt4bc->qtVersion();
ProFileReader *reader = proFileNode->createProFileReader();
ProFileReader *reader = qt4Project()->createProFileReader(proFileNode);
reader->setCumulative(false);
// Find out what flags we pass on to qmake
@@ -299,7 +298,7 @@ void S60DeviceRunConfiguration::updateTarget()
reader->setConfigCommandLineArguments(addedUserConfigArguments, removedUserConfigArguments);
if (!reader->readProFile(m_proFilePath)) {
delete reader;
qt4Project()->destroyProFileReader(reader);
Core::ICore::instance()->messageManager()->printToOutputPane(tr("Could not parse %1. The QtS60 Device run configuration %2 can not be started.").arg(m_proFilePath).arg(name()));
return;
}
@@ -346,7 +345,7 @@ void S60DeviceRunConfiguration::updateTarget()
else
m_target = QLatin1String("urel");
m_baseFileName += QLatin1Char('_') + m_platform + QLatin1Char('_') + m_target;
delete reader;
qt4Project()->destroyProFileReader(reader);
m_cachedTargetInformationValid = true;
emit targetInformationChanged();
}