Debugger: Always include disassembly/frame dump in reports.
This commit is contained in:
@@ -466,20 +466,20 @@ DebugReportGenerator::_DumpDebuggedThreadInfo(BString& _output,
|
|||||||
sizeof(functionName)));
|
sizeof(functionName)));
|
||||||
|
|
||||||
_output << data;
|
_output << data;
|
||||||
if (frame->CountParameters() == 0
|
|
||||||
&& frame->CountLocalVariables() == 0) {
|
// only dump the topmost frame
|
||||||
// only dump the topmost frame
|
if (i == 0) {
|
||||||
if (i == 0) {
|
locker.Unlock();
|
||||||
locker.Unlock();
|
_DumpFunctionDisassembly(_output, frame->InstructionPointer());
|
||||||
_DumpFunctionDisassembly(_output, frame->InstructionPointer());
|
_DumpStackFrameMemory(_output, thread->GetCpuState(),
|
||||||
_DumpStackFrameMemory(_output, thread->GetCpuState(),
|
frame->FrameAddress(), thread->GetTeam()->GetArchitecture()
|
||||||
frame->FrameAddress(), thread->GetTeam()->GetArchitecture()
|
->StackGrowthDirection());
|
||||||
->StackGrowthDirection());
|
locker.Lock();
|
||||||
locker.Lock();
|
|
||||||
}
|
|
||||||
continue;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (frame->CountParameters() == 0 && frame->CountLocalVariables() == 0)
|
||||||
|
continue;
|
||||||
|
|
||||||
_output << "\t\t\tVariables:\n";
|
_output << "\t\t\tVariables:\n";
|
||||||
status_t result = fNodeManager->SetStackFrame(thread, frame);
|
status_t result = fNodeManager->SetStackFrame(thread, frame);
|
||||||
if (result != B_OK)
|
if (result != B_OK)
|
||||||
@@ -538,6 +538,10 @@ DebugReportGenerator::_DumpFunctionDisassembly(BString& _output,
|
|||||||
if (code == NULL) {
|
if (code == NULL) {
|
||||||
switch (function->SourceCodeState()) {
|
switch (function->SourceCodeState()) {
|
||||||
case FUNCTION_SOURCE_NOT_LOADED:
|
case FUNCTION_SOURCE_NOT_LOADED:
|
||||||
|
case FUNCTION_SOURCE_LOADED:
|
||||||
|
// FUNCTION_SOURCE_LOADED is included since, if we entered
|
||||||
|
// here, it implies that the high level source for the
|
||||||
|
// function has been loaded, but the disassembly has not.
|
||||||
function->AddListener(this);
|
function->AddListener(this);
|
||||||
fSourceWaitingFunction = function;
|
fSourceWaitingFunction = function;
|
||||||
fListener->FunctionSourceCodeRequested(instance, true);
|
fListener->FunctionSourceCodeRequested(instance, true);
|
||||||
|
|||||||
Reference in New Issue
Block a user