Move ITEM_DICTIONARY and ITEM_VTABLE_CHUNK to separate subsection of SECTION_Readonly
authorGleb Balykov <g.balykov@samsung.com>
Fri, 23 Jun 2017 12:58:45 +0000 (15:58 +0300)
committerGleb Balykov <g.balykov@samsung.com>
Mon, 10 Jul 2017 13:37:05 +0000 (16:37 +0300)
src/inc/corcompile.h
src/vm/dataimage.cpp
src/zap/zapimage.cpp

index d7ac28d..1274ac2 100644 (file)
@@ -1331,6 +1331,7 @@ class ICorCompilePreloader
     CORCOMPILE_SECTION(READONLY_HOT) \
     CORCOMPILE_SECTION(READONLY_WARM) \
     CORCOMPILE_SECTION(READONLY_COLD) \
+    CORCOMPILE_SECTION(READONLY_VCHUNKS_AND_DICTIONARY) \
     CORCOMPILE_SECTION(CLASS_COLD) \
     CORCOMPILE_SECTION(CROSS_DOMAIN_INFO) \
     CORCOMPILE_SECTION(METHOD_PRECODE_COLD) \
index fc584d7..4e276fe 100644 (file)
@@ -738,9 +738,7 @@ FORCEINLINE static CorCompileSection GetSectionForNodeType(ZapNodeType type)
 
     // SECTION_READONLY_WARM
     case NodeTypeForItemKind(DataImage::ITEM_METHOD_TABLE):
-    case NodeTypeForItemKind(DataImage::ITEM_VTABLE_CHUNK):
     case NodeTypeForItemKind(DataImage::ITEM_INTERFACE_MAP):
-    case NodeTypeForItemKind(DataImage::ITEM_DICTIONARY):
     case NodeTypeForItemKind(DataImage::ITEM_DISPATCH_MAP):
     case NodeTypeForItemKind(DataImage::ITEM_GENERICS_STATIC_FIELDDESCS):
     case NodeTypeForItemKind(DataImage::ITEM_GC_STATIC_HANDLES_COLD):
@@ -750,6 +748,10 @@ FORCEINLINE static CorCompileSection GetSectionForNodeType(ZapNodeType type)
     case NodeTypeForItemKind(DataImage::ITEM_STORED_METHOD_SIG_READONLY_WARM):
         return CORCOMPILE_SECTION_READONLY_WARM;
 
+    case NodeTypeForItemKind(DataImage::ITEM_DICTIONARY):
+    case NodeTypeForItemKind(DataImage::ITEM_VTABLE_CHUNK):
+        return CORCOMPILE_SECTION_READONLY_VCHUNKS_AND_DICTIONARY;
+
     // SECTION_CLASS_COLD
     case NodeTypeForItemKind(DataImage::ITEM_PARAM_TYPEDESC):
     case NodeTypeForItemKind(DataImage::ITEM_ARRAY_TYPEDESC):
index 469b841..0118f47 100644 (file)
@@ -572,6 +572,7 @@ void ZapImage::AllocateVirtualSections()
 #endif // defined(WIN64EXCEPTIONS)
 
         m_pPreloadSections[CORCOMPILE_SECTION_READONLY_WARM] = NewVirtualSection(pTextSection, IBCProfiledSection | WarmRange | ReadonlySection, sizeof(TADDR));
+        m_pPreloadSections[CORCOMPILE_SECTION_READONLY_VCHUNKS_AND_DICTIONARY] = NewVirtualSection(pTextSection, IBCProfiledSection | WarmRange | ReadonlySection, sizeof(TADDR));
 
         //
         // GC Info for methods which were not touched in profiling