Commit 1da7c060 authored by David Schulz's avatar David Schulz
Browse files

Debugger: Always set the cdb symbolpath.

In newer cdb versions the default symbol path points to the microsoft
symbol server. This can lead to a very long start up time for inferiors
including many modules, because every module is verified against that
symbol server. Unless the user does not explicitly set such a symbol
server in the cdb settings do not use a symbol server.

Change-Id: I0b24e2dd12f6cef98c55f4f57f0c800cecfc3c3f
Reviewed-by: default avatarChristian Stenger <>
parent a029aafd
......@@ -544,9 +544,6 @@ bool CdbEngine::launchCDB(const DebuggerRunParameters &sp, QString *errorMessage
if (boolSetting(IgnoreFirstChanceAccessViolation))
arguments << QLatin1String("-x");
const QStringList &symbolPaths = stringListSetting(CdbSymbolPaths);
if (!symbolPaths.isEmpty())
arguments << QLatin1String("-y") << symbolPaths.join(QLatin1Char(';'));
const QStringList &sourcePaths = stringListSetting(CdbSourcePaths);
if (!sourcePaths.isEmpty())
arguments << QLatin1String("-srcpath") << sourcePaths.join(QLatin1Char(';'));
......@@ -642,6 +639,18 @@ void CdbEngine::setupInferior()
runCommand({cdbAddBreakpointCommand(bp, m_sourcePathMappings, id, true), BuiltinCommand,
[this, id](const DebuggerResponse &r) { handleBreakInsert(r, id); }});
// setting up symbol search path
QStringList symbolPaths = stringListSetting(CdbSymbolPaths);
const QProcessEnvironment &env = QProcessEnvironment::systemEnvironment();
QString symbolPath = env.value(QLatin1String("_NT_ALT_SYMBOL_PATH"));
if (!symbolPath.isEmpty())
symbolPaths += symbolPath;
symbolPath = env.value(QLatin1String("_NT_SYMBOL_PATH"));
if (!symbolPath.isEmpty())
symbolPaths += symbolPath;
runCommand({".sympath \"" + symbolPaths.join(QLatin1Char(';')).toLatin1() + '"', NoFlags});
runCommand({"!sym noisy", NoFlags}); // Show symbol load information.
runCommand({"sxn 0x4000001f", NoFlags}); // Do not break on WowX86 exceptions.
runCommand({"sxn ibp", NoFlags}); // Do not break on initial breakpoints.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment