The following patch speeds loading and closing a workspace to about half (at least on my system).
FindTargetsDebugger() is rebuilding the debugger menu system for every activation of a project. It does not need to do this during opening and closing of a workspace since after the workspace is loaded, CB will activated the correct project anyway.
It does not need to do it at all during closing of a workspace. With the patch, closing the CB workspace changed from 7 to less than 1 second.
Index: src/sdk/debuggermanager.cpp
===================================================================
--- src/sdk/debuggermanager.cpp (revision 7937)
+++ src/sdk/debuggermanager.cpp (working copy)
@@ -1146,7 +1146,10 @@
}
void DebuggerManager::FindTargetsDebugger()
-{
+{
+ if (Manager::Get()->GetProjectManager()->IsLoadingOrClosing())
+ return;
+
m_activeDebugger = nullptr;
m_menuHandler->SetActiveDebugger(nullptr);
svn build rev 7937 (2012-04-23 04:29:22) gcc 4.6.1 Windows/unicode - 32 bit
Go on and commit it, we can always revert it, if it breaks something, but I doubt it will.
Sorry, but I cannot commit to CB. I don't have the credentials.
OK, I'll commit it...
In svn.
Quote from: Pecan on April 23, 2012, 06:12:08 PM
Sorry, but I cannot commit to CB. I don't have the credentials.
Why not? You should ask Yiannis to adjust that. I guess its an error...?!