aboutsummaryrefslogtreecommitdiffstats
path: root/src/3rdparty
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-07-05 10:44:55 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-07-05 20:03:35 +0200
commit10be273b3c804d86ee6dde5f550fd76217a8a77d (patch)
tree3a7d6c106987421149e0583681c90c1291eabcf4 /src/3rdparty
parent5d6f8b18fe77d2fc17a3c1d77d1c4baeff0e9704 (diff)
Follow-up to previous commit about forcing thumb builds:
Disable the checks of the thumb bit in code pointers when building for Android, because we want to allow for intermixing of thumb (what the JIT generates) and arm code (what the compiler generates for run-time functions we call, in debug builds) Change-Id: I0bcce4015d18db4e38244a1d1ad89413b3f17152 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/3rdparty')
-rw-r--r--src/3rdparty/masm/assembler/ARMv7Assembler.h3
-rw-r--r--src/3rdparty/masm/assembler/MacroAssemblerCodeRef.h4
2 files changed, 5 insertions, 2 deletions
diff --git a/src/3rdparty/masm/assembler/ARMv7Assembler.h b/src/3rdparty/masm/assembler/ARMv7Assembler.h
index 99a0e82b1a..3a0a435ab9 100644
--- a/src/3rdparty/masm/assembler/ARMv7Assembler.h
+++ b/src/3rdparty/masm/assembler/ARMv7Assembler.h
@@ -30,6 +30,7 @@
#if ENABLE(ASSEMBLER) && CPU(ARM_THUMB2)
#include "AssemblerBuffer.h"
+#include "MacroAssemblerCodeRef.h"
#include <wtf/Assertions.h>
#include <wtf/Vector.h>
#include <stdint.h>
@@ -2111,7 +2112,7 @@ public:
{
ASSERT(!(reinterpret_cast<intptr_t>(code) & 1));
ASSERT(from.isSet());
- ASSERT(reinterpret_cast<intptr_t>(to) & 1);
+ ASSERT_VALID_CODE_POINTER(to);
setPointer(reinterpret_cast<uint16_t*>(reinterpret_cast<intptr_t>(code) + from.m_offset) - 1, to, false);
}
diff --git a/src/3rdparty/masm/assembler/MacroAssemblerCodeRef.h b/src/3rdparty/masm/assembler/MacroAssemblerCodeRef.h
index 89cffb1278..b699316b91 100644
--- a/src/3rdparty/masm/assembler/MacroAssemblerCodeRef.h
+++ b/src/3rdparty/masm/assembler/MacroAssemblerCodeRef.h
@@ -33,10 +33,12 @@
#include <wtf/PassRefPtr.h>
#include <wtf/RefPtr.h>
#include <wtf/UnusedParam.h>
+#include <qglobal.h>
// ASSERT_VALID_CODE_POINTER checks that ptr is a non-null pointer, and that it is a valid
// instruction address on the platform (for example, check any alignment requirements).
-#if CPU(ARM_THUMB2)
+// (Disabled checks on Android/ARM because we want to intermix thumb and arm)
+#if CPU(ARM_THUMB2) && !defined(Q_OS_ANDROID)
// ARM/thumb instructions must be 16-bit aligned, but all code pointers to be loaded
// into the processor are decorated with the bottom bit set, indicating that this is
// thumb code (as oposed to 32-bit traditional ARM). The first test checks for both