Commit c1ad7008 authored by David Schulz's avatar David Schulz Committed by hjk

Debugger: Remove verbose option of the debugger log.

Saves an asking for debugger log roundtrip when the information is just
visible in the verbose log. Was just used inside the cdbengine.

Change-Id: I9801d3ccd8f273c3b4afcf053b00e7af0953a63f
Reviewed-by: default avatarhjk <hjk@theqtcompany.com>
parent 93c18407
......@@ -235,8 +235,6 @@ CdbEngine::CdbEngine(const DebuggerRunParameters &sp) :
m_extensionCommandPrefixBA("!" QT_CREATOR_CDB_EXT "."),
m_operateByInstructionPending(true),
m_operateByInstruction(true), // Default CDB setting
m_verboseLogPending(true),
m_verboseLog(false), // Default CDB setting
m_hasDebuggee(false),
m_wow64State(wow64Uninitialized),
m_elapsedLogTime(0),
......@@ -249,8 +247,6 @@ CdbEngine::CdbEngine(const DebuggerRunParameters &sp) :
connect(action(OperateByInstruction), &QAction::triggered,
this, &CdbEngine::operateByInstructionTriggered);
connect(action(VerboseLog), &QAction::triggered,
this, &CdbEngine::verboseLogTriggered);
connect(action(CreateFullBacktrace), &QAction::triggered,
this, &CdbEngine::createFullBacktrace);
connect(&m_process, static_cast<void(QProcess::*)(int)>(&QProcess::finished),
......@@ -272,9 +268,7 @@ void CdbEngine::init()
m_nextCommandToken = 0;
m_currentBuiltinResponseToken = -1;
m_operateByInstructionPending = action(OperateByInstruction)->isChecked();
m_verboseLogPending = boolSetting(VerboseLog);
m_operateByInstruction = true; // Default CDB setting
m_verboseLog = false; // Default CDB setting
m_hasDebuggee = false;
m_sourceStepInto = false;
m_watchPointX = m_watchPointY = 0;
......@@ -321,13 +315,6 @@ void CdbEngine::operateByInstructionTriggered(bool operateByInstruction)
syncOperateByInstruction(operateByInstruction);
}
void CdbEngine::verboseLogTriggered(bool verboseLog)
{
m_verboseLogPending = verboseLog;
if (state() == InferiorStopOk)
syncVerboseLog(verboseLog);
}
void CdbEngine::syncOperateByInstruction(bool operateByInstruction)
{
if (debug)
......@@ -340,15 +327,6 @@ void CdbEngine::syncOperateByInstruction(bool operateByInstruction)
runCommand({m_operateByInstruction ? "l-s" : "l+s", NoFlags});
}
void CdbEngine::syncVerboseLog(bool verboseLog)
{
if (m_verboseLog == verboseLog)
return;
QTC_ASSERT(m_accessible, return);
m_verboseLog = verboseLog;
runCommand({m_verboseLog ? "!sym noisy" : "!sym quiet", NoFlags});
}
bool CdbEngine::canHandleToolTip(const DebuggerToolTipContext &context) const
{
Q_UNUSED(context);
......@@ -664,6 +642,7 @@ void CdbEngine::setupInferior()
runCommand({cdbAddBreakpointCommand(bp, m_sourcePathMappings, id, true), BuiltinCommand,
[this, id](const DebuggerResponse &r) { handleBreakInsert(r, id); }});
}
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.
runCommand({".asm source_line", NoFlags}); // Source line in assembly
......@@ -1261,8 +1240,7 @@ void CdbEngine::doUpdateLocals(const UpdateParameters &updateParameters)
}
}
}
if (boolSetting(VerboseLog))
str << blankSeparator << "-v";
str << blankSeparator << "-v";
if (boolSetting(UseDebuggingHelpers))
str << blankSeparator << "-c";
if (boolSetting(SortStructMembers))
......@@ -1668,8 +1646,7 @@ void CdbEngine::handleRegistersExt(const DebuggerResponse &response)
void CdbEngine::handleLocals(const DebuggerResponse &response, bool partialUpdate)
{
if (response.resultClass == ResultDone) {
if (boolSetting(VerboseLog))
showMessage(QLatin1String(response.data.toString()), LogDebug);
showMessage(QLatin1String(response.data.toString()), LogDebug);
GdbMi partial;
partial.m_name = "partial";
......@@ -1887,8 +1864,6 @@ void CdbEngine::handleSessionIdle(const QByteArray &messageBA)
elapsedLogTime(), messageBA.constData(),
stateName(state()), m_specialStopMode);
syncVerboseLog(m_verboseLogPending);
// Switch source level debugging
syncOperateByInstruction(m_operateByInstructionPending);
......@@ -2392,8 +2367,7 @@ void CdbEngine::parseOutputLine(QByteArray line)
command.function.data(), m_currentBuiltinResponseToken,
m_currentBuiltinResponse.count('\n'), m_commandForToken.size() - 1);
QTC_ASSERT(token == m_currentBuiltinResponseToken, return);
if (boolSetting(VerboseLog))
showMessage(QLatin1String(m_currentBuiltinResponse), LogMisc);
showMessage(QLatin1String(m_currentBuiltinResponse), LogMisc);
if (command.callback) {
DebuggerResponse response;
response.token = token;
......
......@@ -124,7 +124,6 @@ private slots:
void processFinished();
void runCommand(const DebuggerCommand &cmd) override;
void operateByInstructionTriggered(bool);
void verboseLogTriggered(bool);
void consoleStubError(const QString &);
void consoleStubProcessStarted();
......@@ -184,7 +183,6 @@ private:
inline bool isCdbProcessRunning() const { return m_process.state() != QProcess::NotRunning; }
bool canInterruptInferior() const;
void syncOperateByInstruction(bool operateByInstruction);
void syncVerboseLog(bool verboseLog);
void postWidgetAtCommand();
void handleCustomSpecialStop(const QVariant &v);
void postFetchMemory(const MemoryViewCookie &c);
......@@ -240,8 +238,6 @@ private:
const QByteArray m_extensionCommandPrefixBA; //!< Library name used as prefix
bool m_operateByInstructionPending; //!< Creator operate by instruction action changed.
bool m_operateByInstruction;
bool m_verboseLogPending; //!< Creator verbose log action changed.
bool m_verboseLog;
bool m_hasDebuggee;
enum Wow64State {
wow64Uninitialized,
......
......@@ -211,7 +211,6 @@ CommonOptionsPageWidget::CommonOptionsPageWidget
m_group->insert(action(ShowQObjectNames), 0);
m_group->insert(action(SortStructMembers), 0);
m_group->insert(action(LogTimeStamps), 0);
m_group->insert(action(VerboseLog), 0);
m_group->insert(action(BreakOnThrow), 0);
m_group->insert(action(BreakOnCatch), 0);
if (Utils::HostOsInfo::isWindowsHost()) {
......
......@@ -161,13 +161,6 @@ DebuggerSettings::DebuggerSettings()
item->setDefaultValue(false);
insertItem(LogTimeStamps, item);
item = new SavedAction(this);
item->setText(tr("Verbose Log"));
item->setSettingsKey(debugModeGroup, QLatin1String("VerboseLog"));
item->setCheckable(true);
item->setDefaultValue(false);
insertItem(VerboseLog, item);
item = new SavedAction(this);
item->setText(tr("Operate by Instruction"));
item->setCheckable(true);
......
......@@ -92,7 +92,6 @@ enum DebuggerActionCode
AutoQuit,
LockView,
LogTimeStamps,
VerboseLog,
OperateByInstruction,
CloseSourceBuffersOnExit,
CloseMemoryBuffersOnExit,
......
......@@ -175,7 +175,6 @@ public:
menu->addAction(m_clearContentsAction);
menu->addAction(m_saveContentsAction); // X11 clipboard is unreliable for long texts
menu->addAction(action(LogTimeStamps));
menu->addAction(action(VerboseLog));
menu->addAction(m_reloadDebuggingHelpersAction);
menu->addSeparator();
menu->addAction(action(SettingsDialog));
......
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