2016-08-11 11:09:21 +00:00
|
|
|
#include "stdafx.h"
|
|
|
|
#if defined(__arm__) || defined(_M_ARM)
|
2022-10-10 00:22:17 +00:00
|
|
|
#include <Project64-core/N64System/Recompiler/Arm/ArmOps.h>
|
2023-04-05 00:46:21 +00:00
|
|
|
#include <Project64-core/N64System/Recompiler/CodeBlock.h>
|
2016-08-11 11:09:21 +00:00
|
|
|
|
2022-10-24 00:45:46 +00:00
|
|
|
CArmOps::CArmOps(CCodeBlock & CodeBlock) :
|
2023-04-05 00:46:21 +00:00
|
|
|
asmjit::a64::Assembler(&CodeBlock.CodeHolder()),
|
2022-10-24 00:45:46 +00:00
|
|
|
m_CodeBlock(CodeBlock)
|
2016-08-11 11:09:21 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2023-04-05 00:46:21 +00:00
|
|
|
asmjit::Error CArmOps::_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;
|
|
|
|
}
|
|
|
|
|
2016-08-11 11:09:21 +00:00
|
|
|
#endif
|