Debugger: Added auto-load cdl option

This commit is contained in:
Souryo 2017-08-19 22:00:12 -04:00
parent 8c9567bd47
commit e66dd700e1
8 changed files with 111 additions and 46 deletions

View file

@ -81,7 +81,9 @@ Debugger::Debugger(shared_ptr<Console> console, shared_ptr<CPU> cpu, shared_ptr<
_frozenAddresses.insert(_frozenAddresses.end(), 0x10000, 0);
LoadCdlFile(FolderUtilities::CombinePath(FolderUtilities::GetDebuggerFolder(), FolderUtilities::GetFilename(_romName, false) + ".cdl"));
if(!LoadCdlFile(FolderUtilities::CombinePath(FolderUtilities::GetDebuggerFolder(), FolderUtilities::GetFilename(_romName, false) + ".cdl"))) {
_disassembler->Reset();
}
Debugger::Instance = this;
}
@ -145,24 +147,38 @@ void Debugger::BreakIfDebugging()
bool Debugger::LoadCdlFile(string cdlFilepath)
{
if(_codeDataLogger->LoadCdlFile(cdlFilepath)) {
for(int i = 0, len = _mapper->GetMemorySize(DebugMemoryType::PrgRom); i < len; i++) {
if(_codeDataLogger->IsCode(i)) {
AddressTypeInfo info = { i, AddressType::PrgRom };
i = _disassembler->BuildCache(info, 0, _codeDataLogger->IsSubEntryPoint(i)) - 1;
}
}
for(int i = 0, len = _mapper->GetMemorySize(DebugMemoryType::PrgRom); i < len; i++) {
if(_codeDataLogger->IsSubEntryPoint(i)) {
_functionEntryPoints.emplace(i);
}
}
UpdateCdlCache();
return true;
}
return false;
}
void Debugger::ResetCdl()
{
_codeDataLogger->Reset();
UpdateCdlCache();
}
void Debugger::UpdateCdlCache()
{
Console::Pause();
_disassembler->Reset();
for(int i = 0, len = _mapper->GetMemorySize(DebugMemoryType::PrgRom); i < len; i++) {
if(_codeDataLogger->IsCode(i)) {
AddressTypeInfo info = { i, AddressType::PrgRom };
i = _disassembler->BuildCache(info, 0, _codeDataLogger->IsSubEntryPoint(i)) - 1;
}
}
_functionEntryPoints.clear();
for(int i = 0, len = _mapper->GetMemorySize(DebugMemoryType::PrgRom); i < len; i++) {
if(_codeDataLogger->IsSubEntryPoint(i)) {
_functionEntryPoints.emplace(i);
}
}
Console::Resume();
}
bool Debugger::IsMarkedAsCode(uint16_t relativeAddress)
{
AddressTypeInfo info;

View file

@ -155,6 +155,8 @@ public:
void Run();
bool LoadCdlFile(string cdlFilepath);
void ResetCdl();
void UpdateCdlCache();
bool IsMarkedAsCode(uint16_t relativeAddress);
shared_ptr<CodeDataLogger> GetCodeDataLogger();

View file

@ -16,11 +16,6 @@ Disassembler::Disassembler(MemoryManager* memoryManager, BaseMapper* mapper, Deb
_memoryManager = memoryManager;
_mapper = mapper;
_disassembleCache.insert(_disassembleCache.end(), mapper->GetMemorySize(DebugMemoryType::PrgRom), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleWorkRamCache.insert(_disassembleWorkRamCache.end(), mapper->GetMemorySize(DebugMemoryType::WorkRam), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleSaveRamCache.insert(_disassembleSaveRamCache.end(), mapper->GetMemorySize(DebugMemoryType::SaveRam), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleMemoryCache.insert(_disassembleMemoryCache.end(), 0x800, shared_ptr<DisassemblyInfo>(nullptr));
BuildOpCodeTables(false);
}
@ -28,6 +23,19 @@ Disassembler::~Disassembler()
{
}
void Disassembler::Reset()
{
_disassembleCache.clear();
_disassembleWorkRamCache.clear();
_disassembleSaveRamCache.clear();
_disassembleMemoryCache.clear();
_disassembleCache.insert(_disassembleCache.end(), _mapper->GetMemorySize(DebugMemoryType::PrgRom), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleWorkRamCache.insert(_disassembleWorkRamCache.end(), _mapper->GetMemorySize(DebugMemoryType::WorkRam), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleSaveRamCache.insert(_disassembleSaveRamCache.end(), _mapper->GetMemorySize(DebugMemoryType::SaveRam), shared_ptr<DisassemblyInfo>(nullptr));
_disassembleMemoryCache.insert(_disassembleMemoryCache.end(), 0x800, shared_ptr<DisassemblyInfo>(nullptr));
}
void Disassembler::BuildOpCodeTables(bool useLowerCase)
{
string opName[256] = {

View file

@ -34,6 +34,7 @@ public:
~Disassembler();
void BuildOpCodeTables(bool useLowerCase);
void Reset();
uint32_t BuildCache(AddressTypeInfo &info, uint16_t memoryAddr, bool isSubEntryPoint);
void InvalidateCache(AddressTypeInfo &info);

View file

@ -143,6 +143,7 @@ namespace Mesen.GUI.Config
public string FindOccurrencesLastSearch = string.Empty;
public bool AutoLoadDbgFiles = false;
public bool AutoLoadCdlFiles = false;
public bool DisableDefaultLabels = false;
public bool RefreshWatchWhileRunning = false;

View file

@ -152,6 +152,7 @@ namespace Mesen.GUI.Debugger
this.lblCyclesElapsed = new System.Windows.Forms.ToolStripStatusLabel();
this.ctrlPpuMemoryMapping = new Mesen.GUI.Debugger.Controls.ctrlMemoryMapping();
this.ctrlCpuMemoryMapping = new Mesen.GUI.Debugger.Controls.ctrlMemoryMapping();
this.mnuAutoLoadCdlFiles = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.splitContainer)).BeginInit();
this.splitContainer.Panel1.SuspendLayout();
this.splitContainer.Panel2.SuspendLayout();
@ -196,7 +197,7 @@ namespace Mesen.GUI.Debugger
this.splitContainer.Panel2.Controls.Add(this.tableLayoutPanel10);
this.splitContainer.Panel2MinSize = 100;
this.splitContainer.Size = new System.Drawing.Size(1172, 573);
this.splitContainer.SplitterDistance = 435;
this.splitContainer.SplitterDistance = 432;
this.splitContainer.SplitterWidth = 7;
this.splitContainer.TabIndex = 1;
this.splitContainer.TabStop = false;
@ -219,8 +220,8 @@ namespace Mesen.GUI.Debugger
//
this.ctrlSplitContainerTop.Panel2.Controls.Add(this.tlpFunctionLabelLists);
this.ctrlSplitContainerTop.Panel2MinSize = 150;
this.ctrlSplitContainerTop.Size = new System.Drawing.Size(1172, 435);
this.ctrlSplitContainerTop.SplitterDistance = 914;
this.ctrlSplitContainerTop.Size = new System.Drawing.Size(1172, 432);
this.ctrlSplitContainerTop.SplitterDistance = 911;
this.ctrlSplitContainerTop.SplitterWidth = 7;
this.ctrlSplitContainerTop.TabIndex = 3;
this.ctrlSplitContainerTop.PanelCollapsed += new System.EventHandler(this.ctrlSplitContainerTop_PanelCollapsed);
@ -241,7 +242,7 @@ namespace Mesen.GUI.Debugger
this.tlpTop.Name = "tlpTop";
this.tlpTop.RowCount = 1;
this.tlpTop.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tlpTop.Size = new System.Drawing.Size(914, 435);
this.tlpTop.Size = new System.Drawing.Size(911, 432);
this.tlpTop.TabIndex = 2;
//
// ctrlDebuggerCode
@ -250,7 +251,7 @@ namespace Mesen.GUI.Debugger
this.ctrlDebuggerCode.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlDebuggerCode.Location = new System.Drawing.Point(3, 3);
this.ctrlDebuggerCode.Name = "ctrlDebuggerCode";
this.ctrlDebuggerCode.Size = new System.Drawing.Size(450, 429);
this.ctrlDebuggerCode.Size = new System.Drawing.Size(447, 426);
this.ctrlDebuggerCode.TabIndex = 2;
this.ctrlDebuggerCode.OnEditCode += new Mesen.GUI.Debugger.ctrlDebuggerCode.AssemblerEventHandler(this.ctrlDebuggerCode_OnEditCode);
this.ctrlDebuggerCode.OnSetNextStatement += new Mesen.GUI.Debugger.ctrlDebuggerCode.AddressEventHandler(this.ctrlDebuggerCode_OnSetNextStatement);
@ -259,10 +260,10 @@ namespace Mesen.GUI.Debugger
// ctrlConsoleStatus
//
this.ctrlConsoleStatus.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlConsoleStatus.Location = new System.Drawing.Point(456, 0);
this.ctrlConsoleStatus.Location = new System.Drawing.Point(453, 0);
this.ctrlConsoleStatus.Margin = new System.Windows.Forms.Padding(0);
this.ctrlConsoleStatus.Name = "ctrlConsoleStatus";
this.ctrlConsoleStatus.Size = new System.Drawing.Size(458, 435);
this.ctrlConsoleStatus.Size = new System.Drawing.Size(458, 432);
this.ctrlConsoleStatus.TabIndex = 3;
this.ctrlConsoleStatus.OnGotoLocation += new System.EventHandler(this.ctrlConsoleStatus_OnGotoLocation);
//
@ -270,9 +271,9 @@ namespace Mesen.GUI.Debugger
//
this.ctrlDebuggerCodeSplit.Code = null;
this.ctrlDebuggerCodeSplit.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlDebuggerCodeSplit.Location = new System.Drawing.Point(459, 3);
this.ctrlDebuggerCodeSplit.Location = new System.Drawing.Point(456, 3);
this.ctrlDebuggerCodeSplit.Name = "ctrlDebuggerCodeSplit";
this.ctrlDebuggerCodeSplit.Size = new System.Drawing.Size(1, 429);
this.ctrlDebuggerCodeSplit.Size = new System.Drawing.Size(1, 426);
this.ctrlDebuggerCodeSplit.TabIndex = 4;
this.ctrlDebuggerCodeSplit.Visible = false;
this.ctrlDebuggerCodeSplit.OnEditCode += new Mesen.GUI.Debugger.ctrlDebuggerCode.AssemblerEventHandler(this.ctrlDebuggerCode_OnEditCode);
@ -292,16 +293,16 @@ namespace Mesen.GUI.Debugger
this.tlpFunctionLabelLists.RowCount = 2;
this.tlpFunctionLabelLists.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tlpFunctionLabelLists.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tlpFunctionLabelLists.Size = new System.Drawing.Size(251, 435);
this.tlpFunctionLabelLists.Size = new System.Drawing.Size(254, 432);
this.tlpFunctionLabelLists.TabIndex = 5;
//
// grpLabels
//
this.grpLabels.Controls.Add(this.ctrlLabelList);
this.grpLabels.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpLabels.Location = new System.Drawing.Point(3, 220);
this.grpLabels.Location = new System.Drawing.Point(3, 219);
this.grpLabels.Name = "grpLabels";
this.grpLabels.Size = new System.Drawing.Size(245, 212);
this.grpLabels.Size = new System.Drawing.Size(248, 210);
this.grpLabels.TabIndex = 6;
this.grpLabels.TabStop = false;
this.grpLabels.Text = "Labels";
@ -311,7 +312,7 @@ namespace Mesen.GUI.Debugger
this.ctrlLabelList.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlLabelList.Location = new System.Drawing.Point(3, 16);
this.ctrlLabelList.Name = "ctrlLabelList";
this.ctrlLabelList.Size = new System.Drawing.Size(239, 193);
this.ctrlLabelList.Size = new System.Drawing.Size(242, 191);
this.ctrlLabelList.TabIndex = 0;
this.ctrlLabelList.OnFindOccurrence += new System.EventHandler(this.ctrlLabelList_OnFindOccurrence);
this.ctrlLabelList.OnLabelSelected += new System.EventHandler(this.ctrlLabelList_OnLabelSelected);
@ -322,7 +323,7 @@ namespace Mesen.GUI.Debugger
this.grpFunctions.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpFunctions.Location = new System.Drawing.Point(3, 3);
this.grpFunctions.Name = "grpFunctions";
this.grpFunctions.Size = new System.Drawing.Size(245, 211);
this.grpFunctions.Size = new System.Drawing.Size(248, 210);
this.grpFunctions.TabIndex = 5;
this.grpFunctions.TabStop = false;
this.grpFunctions.Text = "Functions";
@ -332,7 +333,7 @@ namespace Mesen.GUI.Debugger
this.ctrlFunctionList.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlFunctionList.Location = new System.Drawing.Point(3, 16);
this.ctrlFunctionList.Name = "ctrlFunctionList";
this.ctrlFunctionList.Size = new System.Drawing.Size(239, 192);
this.ctrlFunctionList.Size = new System.Drawing.Size(242, 191);
this.ctrlFunctionList.TabIndex = 0;
this.ctrlFunctionList.OnFindOccurrence += new System.EventHandler(this.ctrlFunctionList_OnFindOccurrence);
this.ctrlFunctionList.OnFunctionSelected += new System.EventHandler(this.ctrlFunctionList_OnFunctionSelected);
@ -353,7 +354,7 @@ namespace Mesen.GUI.Debugger
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle());
this.tableLayoutPanel10.RowStyles.Add(new System.Windows.Forms.RowStyle());
this.tableLayoutPanel10.Size = new System.Drawing.Size(1172, 131);
this.tableLayoutPanel10.Size = new System.Drawing.Size(1172, 134);
this.tableLayoutPanel10.TabIndex = 0;
//
// grpWatch
@ -363,7 +364,7 @@ namespace Mesen.GUI.Debugger
this.grpWatch.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpWatch.Location = new System.Drawing.Point(3, 3);
this.grpWatch.Name = "grpWatch";
this.grpWatch.Size = new System.Drawing.Size(384, 125);
this.grpWatch.Size = new System.Drawing.Size(384, 128);
this.grpWatch.TabIndex = 2;
this.grpWatch.TabStop = false;
this.grpWatch.Text = "Watch";
@ -383,7 +384,7 @@ namespace Mesen.GUI.Debugger
this.ctrlWatch.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlWatch.Location = new System.Drawing.Point(3, 16);
this.ctrlWatch.Name = "ctrlWatch";
this.ctrlWatch.Size = new System.Drawing.Size(378, 106);
this.ctrlWatch.Size = new System.Drawing.Size(378, 109);
this.ctrlWatch.TabIndex = 0;
//
// grpBreakpoints
@ -392,7 +393,7 @@ namespace Mesen.GUI.Debugger
this.grpBreakpoints.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpBreakpoints.Location = new System.Drawing.Point(393, 3);
this.grpBreakpoints.Name = "grpBreakpoints";
this.grpBreakpoints.Size = new System.Drawing.Size(384, 125);
this.grpBreakpoints.Size = new System.Drawing.Size(384, 128);
this.grpBreakpoints.TabIndex = 3;
this.grpBreakpoints.TabStop = false;
this.grpBreakpoints.Text = "Breakpoints";
@ -402,7 +403,7 @@ namespace Mesen.GUI.Debugger
this.ctrlBreakpoints.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlBreakpoints.Location = new System.Drawing.Point(3, 16);
this.ctrlBreakpoints.Name = "ctrlBreakpoints";
this.ctrlBreakpoints.Size = new System.Drawing.Size(378, 106);
this.ctrlBreakpoints.Size = new System.Drawing.Size(378, 109);
this.ctrlBreakpoints.TabIndex = 0;
this.ctrlBreakpoints.BreakpointNavigation += new System.EventHandler(this.ctrlBreakpoints_BreakpointNavigation);
//
@ -412,7 +413,7 @@ namespace Mesen.GUI.Debugger
this.grpCallstack.Dock = System.Windows.Forms.DockStyle.Fill;
this.grpCallstack.Location = new System.Drawing.Point(783, 3);
this.grpCallstack.Name = "grpCallstack";
this.grpCallstack.Size = new System.Drawing.Size(386, 125);
this.grpCallstack.Size = new System.Drawing.Size(386, 128);
this.grpCallstack.TabIndex = 4;
this.grpCallstack.TabStop = false;
this.grpCallstack.Text = "Call Stack";
@ -422,7 +423,7 @@ namespace Mesen.GUI.Debugger
this.ctrlCallstack.Dock = System.Windows.Forms.DockStyle.Fill;
this.ctrlCallstack.Location = new System.Drawing.Point(3, 16);
this.ctrlCallstack.Name = "ctrlCallstack";
this.ctrlCallstack.Size = new System.Drawing.Size(380, 106);
this.ctrlCallstack.Size = new System.Drawing.Size(380, 109);
this.ctrlCallstack.TabIndex = 0;
this.ctrlCallstack.FunctionSelected += new System.EventHandler(this.ctrlCallstack_FunctionSelected);
//
@ -492,6 +493,7 @@ namespace Mesen.GUI.Debugger
this.mnuResetWorkspace,
this.toolStripMenuItem10,
this.mnuAutoLoadDbgFiles,
this.mnuAutoLoadCdlFiles,
this.mnuDisableDefaultLabels});
this.mnuWorkspace.Name = "mnuWorkspace";
this.mnuWorkspace.Size = new System.Drawing.Size(162, 22);
@ -1286,6 +1288,14 @@ namespace Mesen.GUI.Debugger
this.ctrlCpuMemoryMapping.Text = "ctrlMemoryMapping1";
this.ctrlCpuMemoryMapping.Visible = false;
//
// mnuAutoLoadCdlFiles
//
this.mnuAutoLoadCdlFiles.CheckOnClick = true;
this.mnuAutoLoadCdlFiles.Name = "mnuAutoLoadCdlFiles";
this.mnuAutoLoadCdlFiles.Size = new System.Drawing.Size(207, 22);
this.mnuAutoLoadCdlFiles.Text = "Auto-load CDL files";
this.mnuAutoLoadCdlFiles.Click += new System.EventHandler(this.mnuAutoLoadCdlFiles_Click);
//
// frmDebugger
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@ -1450,5 +1460,6 @@ namespace Mesen.GUI.Debugger
private System.Windows.Forms.ToolStripMenuItem mnuExportLabels;
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem16;
private System.Windows.Forms.ToolStripMenuItem mnuSaveAsIps;
private System.Windows.Forms.ToolStripMenuItem mnuAutoLoadCdlFiles;
}
}

View file

@ -47,7 +47,8 @@ namespace Mesen.GUI.Debugger
ctrlProfiler.OnFunctionSelected += ctrlProfiler_OnFunctionSelected;
this.UpdateWorkspace();
this.AutoLoadDbgFile(true);
this.AutoLoadCdlFiles();
this.AutoLoadDbgFiles(true);
this.mnuSplitView.Checked = ConfigManager.Config.DebugInfo.SplitView;
this.mnuPpuPartialDraw.Checked = ConfigManager.Config.DebugInfo.PpuPartialDraw;
@ -57,6 +58,7 @@ namespace Mesen.GUI.Debugger
this.mnuShowOnlyDisassembledCode.Checked = ConfigManager.Config.DebugInfo.ShowOnlyDisassembledCode;
this.mnuHighlightUnexecutedCode.Checked = ConfigManager.Config.DebugInfo.HighlightUnexecutedCode;
this.mnuAutoLoadDbgFiles.Checked = ConfigManager.Config.DebugInfo.AutoLoadDbgFiles;
this.mnuAutoLoadCdlFiles.Checked = ConfigManager.Config.DebugInfo.AutoLoadCdlFiles;
this.mnuBreakOnReset.Checked = ConfigManager.Config.DebugInfo.BreakOnReset;
this.mnuBreakOnOpen.Checked = ConfigManager.Config.DebugInfo.BreakOnOpen;
this.mnuBreakOnUnofficialOpcodes.Checked = ConfigManager.Config.DebugInfo.BreakOnUnofficialOpcodes;
@ -146,7 +148,21 @@ namespace Mesen.GUI.Debugger
}
}
private void AutoLoadDbgFile(bool silent)
private void AutoLoadCdlFiles()
{
if(ConfigManager.Config.DebugInfo.AutoLoadCdlFiles) {
//This loads CDL files that are next to the rom - useful when developing with a compiler that can produce a CDL file
RomInfo info = InteropEmu.GetRomInfo();
string cdlPath = Path.Combine(info.RomFile.Folder, info.GetRomName() + ".cdl");
if(File.Exists(cdlPath)) {
if(InteropEmu.DebugLoadCdlFile(cdlPath)) {
UpdateDebugger();
}
}
}
}
private void AutoLoadDbgFiles(bool silent)
{
if(ConfigManager.Config.DebugInfo.AutoLoadDbgFiles) {
RomInfo info = InteropEmu.GetRomInfo();
@ -232,7 +248,8 @@ namespace Mesen.GUI.Debugger
mnuEditHeader.Enabled = mnuSaveRom.Enabled = InteropEmu.GetRomInfo().Format == RomFormat.iNes;
this.UpdateWorkspace();
this.AutoLoadDbgFile(true);
this.AutoLoadCdlFiles();
this.AutoLoadDbgFiles(true);
UpdateDebugger();
BreakpointManager.SetBreakpoints();
@ -588,6 +605,7 @@ namespace Mesen.GUI.Debugger
private void mnuResetCdlLog_Click(object sender, EventArgs e)
{
InteropEmu.DebugResetCdlLog();
UpdateDebugger();
}
private void ctrlBreakpoints_BreakpointNavigation(object sender, EventArgs e)
@ -778,8 +796,16 @@ namespace Mesen.GUI.Debugger
if(_debuggerInitialized) {
ConfigManager.Config.DebugInfo.AutoLoadDbgFiles = mnuAutoLoadDbgFiles.Checked;
ConfigManager.ApplyChanges();
AutoLoadDbgFiles(false);
}
}
AutoLoadDbgFile(false);
private void mnuAutoLoadCdlFiles_Click(object sender, EventArgs e)
{
if(_debuggerInitialized) {
ConfigManager.Config.DebugInfo.AutoLoadCdlFiles = mnuAutoLoadCdlFiles.Checked;
ConfigManager.ApplyChanges();
AutoLoadCdlFiles();
}
}

View file

@ -73,7 +73,7 @@ extern "C"
DllExport bool __stdcall DebugLoadCdlFile(char* cdlFilepath) { return GetDebugger()->LoadCdlFile(cdlFilepath); }
DllExport bool __stdcall DebugSaveCdlFile(char* cdlFilepath) { return GetDebugger()->GetCodeDataLogger()->SaveCdlFile(cdlFilepath); }
DllExport void __stdcall DebugGetCdlRatios(CdlRatios* cdlRatios) { *cdlRatios = GetDebugger()->GetCodeDataLogger()->GetRatios(); }
DllExport void __stdcall DebugResetCdlLog() { GetDebugger()->GetCodeDataLogger()->Reset(); }
DllExport void __stdcall DebugResetCdlLog() { GetDebugger()->ResetCdl(); }
DllExport int32_t __stdcall DebugEvaluateExpression(char* expression, EvalResultType *resultType) { return GetDebugger()->EvaluateExpression(expression, *resultType); }