project64/Source/Project64-core/N64System/Recompiler/Aarch64/Aarch64ops.cpp

25 lines
703 B
C++
Raw Normal View History

2022-09-26 03:23:14 +00:00
#include "stdafx.h"
#if defined(__aarch64__)
#include <Project64-core/N64System/Recompiler/Aarch64/Aarch64ops.h>
2023-04-05 00:46:21 +00:00
#include <Project64-core/N64System/Recompiler/CodeBlock.h>
2022-09-26 03:23:14 +00:00
CAarch64Ops::CAarch64Ops(CCodeBlock & CodeBlock) :
2023-04-05 00:46:21 +00:00
asmjit::a64::Assembler(&CodeBlock.CodeHolder()),
2022-09-26 03:23:14 +00:00
m_CodeBlock(CodeBlock)
{
}
2023-04-05 00:46:21 +00:00
asmjit::Error CAarch64Ops::_log(const char * data, size_t size) noexcept
{
stdstr AsmjitLog(std::string(data, size));
AsmjitLog.Trim("\n");
for (SymbolMap::const_iterator itr = m_Symbols.begin(); itr != m_Symbols.end(); itr++)
{
AsmjitLog.Replace(itr->first, itr->second);
}
m_CodeBlock.Log(" %s", AsmjitLog.c_str());
return asmjit::kErrorOk;
}
2022-09-26 03:23:14 +00:00
#endif