summaryrefslogtreecommitdiff
path: root/packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch
diff options
context:
space:
mode:
Diffstat (limited to 'packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch')
-rw-r--r--packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch112
1 files changed, 112 insertions, 0 deletions
diff --git a/packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch b/packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch
new file mode 100644
index 0000000000..08f45e3734
--- /dev/null
+++ b/packaging/0038-Replace-PLATFORM_UNIX-_TARGET_ARM_-for-NGEN-relocati.patch
@@ -0,0 +1,112 @@
+From dc692676bb385477d702f173c04e9ff5af015126 Mon Sep 17 00:00:00 2001
+From: Gleb Balykov <g.balykov@samsung.com>
+Date: Fri, 20 Apr 2018 11:54:18 +0300
+Subject: [PATCH 38/47] Replace PLATFORM_UNIX && _TARGET_ARM_ for NGEN
+ relocations optimizations with FEATURE_NGEN_RELOCS_OPTIMIZATIONS
+
+---
+ src/vm/method.hpp | 4 ++--
+ src/vm/methodtable.h | 16 ++++++++--------
+ 2 files changed, 10 insertions(+), 10 deletions(-)
+
+diff --git a/src/vm/method.hpp b/src/vm/method.hpp
+index 92fbdee..d60984c 100644
+--- a/src/vm/method.hpp
++++ b/src/vm/method.hpp
+@@ -2599,7 +2599,7 @@ public:
+ };
+
+ // The writeable part of the methoddesc.
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativePointer<PTR_NDirectWriteableData> m_pWriteableData;
+ #else
+ PlainPointer<PTR_NDirectWriteableData> m_pWriteableData;
+@@ -3415,7 +3415,7 @@ public: // <TODO>make private: JITinterface.cpp accesses through this </TODO>
+ //
+ // For generic method definitions that are not the typical method definition (e.g. C<int>.m<U>)
+ // this field is null; to obtain the instantiation use LoadMethodInstantiation
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativePointer<PTR_Dictionary> m_pPerInstInfo; //SHARED
+ #else
+ PlainPointer<PTR_Dictionary> m_pPerInstInfo; //SHARED
+diff --git a/src/vm/methodtable.h b/src/vm/methodtable.h
+index 5cc6f45..32b4ca4 100644
+--- a/src/vm/methodtable.h
++++ b/src/vm/methodtable.h
+@@ -112,7 +112,7 @@ struct InterfaceInfo_t
+ #endif
+
+ // Method table of the interface
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativeFixupPointer<PTR_MethodTable> m_pMethodTable;
+ #else
+ FixupPointer<PTR_MethodTable> m_pMethodTable;
+@@ -1622,7 +1622,7 @@ public:
+ #define VTABLE_SLOTS_PER_CHUNK 8
+ #define VTABLE_SLOTS_PER_CHUNK_LOG2 3
+
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_) && defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ typedef RelativePointer<PCODE> VTableIndir2_t;
+ typedef RelativePointer<DPTR(VTableIndir2_t)> VTableIndir_t;
+ #else
+@@ -2136,7 +2136,7 @@ public:
+ // THE METHOD TABLE PARENT (SUPERCLASS/BASE CLASS)
+ //
+
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ #define PARENT_MT_FIXUP_OFFSET (-FIXUP_POINTER_INDIRECTION)
+ typedef RelativeFixupPointer<PTR_MethodTable> ParentMT_t;
+ #else
+@@ -2168,7 +2168,7 @@ public:
+ inline static PTR_VOID GetParentMethodTableOrIndirection(PTR_VOID pMT)
+ {
+ WRAPPER_NO_CONTRACT;
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ PTR_MethodTable pMethodTable = dac_cast<PTR_MethodTable>(pMT);
+ PTR_MethodTable pParentMT = ReadPointerMaybeNull((MethodTable*) pMethodTable, &MethodTable::m_pParentMethodTable);
+ return dac_cast<PTR_VOID>(pParentMT);
+@@ -3066,7 +3066,7 @@ public:
+ // must have a dictionary entry. On the other hand, for instantiations shared with Dict<string,double> the opposite holds.
+ //
+
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ typedef RelativePointer<PTR_Dictionary> PerInstInfoElem_t;
+ typedef RelativePointer<DPTR(PerInstInfoElem_t)> PerInstInfo_t;
+ #else
+@@ -4151,7 +4151,7 @@ private:
+
+ RelativePointer<PTR_Module> m_pLoaderModule; // LoaderModule. It is equal to the ZapModule in ngened images
+
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativePointer<PTR_MethodTableWriteableData> m_pWriteableData;
+ #else
+ PlainPointer<PTR_MethodTableWriteableData> m_pWriteableData;
+@@ -4167,7 +4167,7 @@ private:
+ static const TADDR UNION_MASK = 3;
+
+ union {
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativePointer<DPTR(EEClass)> m_pEEClass;
+ RelativePointer<TADDR> m_pCanonMT;
+ #else
+@@ -4202,7 +4202,7 @@ private:
+ public:
+ union
+ {
+-#if defined(PLATFORM_UNIX) && defined(_TARGET_ARM_)
++#if defined(FEATURE_NGEN_RELOCS_OPTIMIZATIONS)
+ RelativePointer<PTR_InterfaceInfo> m_pInterfaceMap;
+ #else
+ PlainPointer<PTR_InterfaceInfo> m_pInterfaceMap;
+--
+2.7.4
+