Files
asmjit-asmjit/src/asmjit/base/error.cpp
T
kobalicekp f1ce2383ba - Major documentation reorganization of AsmJit (still far from perfection)
- Documentation - removed verbose @brief and switched to markdown syntax which Doxygen supports.
- Added inline documentation to AVX/AVX2 instructions.
- Added more documentation notes to utility classes.
- Modified documentation groups to be compatible with the new code layout (base/x86).

- Renamed VirtualMemoryManager to VMemMgr.
- Removed MemoryManager interface (not needed).
- Changed JitRuntime to always create a new isolated VMemMgr instance.
- Fixed WinRemoteRuntime to work with the new changes.

- Added missing insertps instruction to database, assembler and compiler.
- Moved global functions in x86cpuinfo to CpuUtil class.

- Should notify Issue #10
2014-05-04 23:11:12 +02:00

73 lines
1.7 KiB
C++

// [AsmJit]
// Complete x86/x64 JIT and Remote Assembler for C++.
//
// [License]
// Zlib - See LICENSE.md file in the package.
// [Export]
#define ASMJIT_EXPORTS
// [Dependencies - AsmJit]
#include "../base/error.h"
#include "../base/intutil.h"
// [Api-Begin]
#include "../apibegin.h"
namespace asmjit {
// ============================================================================
// [asmjit::ErrorHandler - Construction / Destruction]
// ============================================================================
ErrorHandler::ErrorHandler() {}
ErrorHandler::~ErrorHandler() {}
// ============================================================================
// [asmjit::ErrorHandler - Interface]
// ============================================================================
ErrorHandler* ErrorHandler::addRef() const {
return const_cast<ErrorHandler*>(this);
}
void ErrorHandler::release() {}
// ============================================================================
// [asmjit::ErrorUtil - AsString]
// ============================================================================
static const char* errorMessages[] = {
"Ok",
"No heap memory",
"No virtual memory",
"Invalid argument",
"Invalid state",
"Unknown instruction",
"Illegal instruction",
"Illegal addressing",
"Illegal short jump",
"No function defined",
"Incomplete function",
"Overlapped arguments",
"No registers",
"Overlapped registers",
"Incompatible argument",
"Incompatible return",
"Unknown error"
};
const char* ErrorUtil::asString(Error e) {
return errorMessages[IntUtil::iMin<Error>(e, kErrorCount)];
}
} // asmjit namespace
// [Api-End]
#include "../apiend.h"