deps: reapply patches to vixl
This commit is contained in:
parent
daf8230cca
commit
f9da57d87f
|
@ -58,7 +58,7 @@ void Assembler::bind(Label* label) {
|
|||
|
||||
|
||||
void Assembler::BindToOffset(Label* label, ptrdiff_t offset) {
|
||||
VIXL_ASSERT((offset >= 0) && (offset <= GetBuffer()->GetCursorOffset()));
|
||||
// VIXL_ASSERT((offset >= 0) && (offset <= GetBuffer()->GetCursorOffset())); // hack to have negative offsets
|
||||
VIXL_ASSERT(offset % kInstructionSize == 0);
|
||||
|
||||
label->Bind(offset);
|
||||
|
|
|
@ -49,7 +49,7 @@ class Label {
|
|||
VIXL_ASSERT(!IsLinked());
|
||||
}
|
||||
|
||||
bool IsBound() const { return location_ >= 0; }
|
||||
bool IsBound() const { return location_ != kLocationUnbound; }
|
||||
bool IsLinked() const { return !links_.empty(); }
|
||||
|
||||
ptrdiff_t GetLocation() const { return location_; }
|
||||
|
|
|
@ -2698,6 +2698,7 @@ void MacroAssembler::PrintfNoPreserve(const char* format,
|
|||
}
|
||||
dc32(arg_pattern_list); // kPrintfArgPatternListOffset
|
||||
} else {
|
||||
#undef printf
|
||||
Register tmp = temps.AcquireX();
|
||||
Mov(tmp, reinterpret_cast<uintptr_t>(printf));
|
||||
Blr(tmp);
|
||||
|
|
|
@ -75,7 +75,7 @@ class CodeBuffer {
|
|||
template <typename T>
|
||||
T GetOffsetAddress(ptrdiff_t offset) const {
|
||||
VIXL_STATIC_ASSERT(sizeof(T) >= sizeof(uintptr_t));
|
||||
VIXL_ASSERT((offset >= 0) && (offset <= (cursor_ - buffer_)));
|
||||
//VIXL_ASSERT((offset >= 0) && (offset <= (cursor_ - buffer_))); // hack to have negative offsets
|
||||
return reinterpret_cast<T>(buffer_ + offset);
|
||||
}
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ class CodeBufferCheckScope {
|
|||
VIXL_ASSERT(!initialised_);
|
||||
VIXL_ASSERT(assembler != NULL);
|
||||
assembler_ = assembler;
|
||||
if (check_policy == kReserveBufferSpace) {
|
||||
if (check_policy == kReserveBufferSpace && assembler->GetBuffer()->IsManaged()) {
|
||||
assembler->GetBuffer()->EnsureSpaceFor(size);
|
||||
}
|
||||
#ifdef VIXL_DEBUG
|
||||
|
|
|
@ -32,6 +32,31 @@ extern "C" {
|
|||
#include <signal.h>
|
||||
}
|
||||
|
||||
#define VIXL_INCLUDE_TARGET_A32
|
||||
#define VIXL_CODE_BUFFER_MALLOC
|
||||
//#define VIXL_DEBUG
|
||||
|
||||
#if defined(__ANDROID__) && defined(VIXL_DEBUG)
|
||||
#include <android/log.h>
|
||||
|
||||
#ifdef printf
|
||||
#undef printf
|
||||
#endif
|
||||
|
||||
#ifdef puts
|
||||
#undef puts
|
||||
#endif
|
||||
|
||||
#define LOG_TAG "flycast"
|
||||
#define LOGI(...) __android_log_print(ANDROID_LOG_INFO,LOG_TAG,__VA_ARGS__)
|
||||
#define LOGW(...) __android_log_print(ANDROID_LOG_WARN,LOG_TAG,__VA_ARGS__)
|
||||
#define LOGE(...) __android_log_print(ANDROID_LOG_ERROR,LOG_TAG,__VA_ARGS__)
|
||||
#define LOGD(...) __android_log_print(ANDROID_LOG_DEBUG,LOG_TAG,__VA_ARGS__)
|
||||
#define puts LOGI
|
||||
#define printf LOGI
|
||||
#define putinf LOGI
|
||||
#endif
|
||||
|
||||
namespace vixl {
|
||||
inline void HostBreakpoint() { raise(SIGINT); }
|
||||
} // namespace vixl
|
||||
|
|
Loading…
Reference in New Issue